MiniQuake

src/miniquake/render/gl_rmain.ml

Package
miniquake.render.gl_rmain
Reachable
No

Imports

Declarations

Add

function Add(left, right)

Add state for add.

ParameterTypeDefaultDescription
leftdynamic—The left input consumed by `Add`.
rightdynamic—The right input consumed by `Add`.

View source

Bind

function Bind(texture)

Implements the `Bind` operation for `miniquake.render.gl_rmain` (bind).

ParameterTypeDefaultDescription
texturedynamic—Texture resource processed by the operation.

View source

blendColor

blendColor

Tracks the module-level blend color state owned by `miniquake.render.gl_rmain`.

View source

BoxOnPlaneSide

function BoxOnPlaneSide(mins, maxs, plane)

Implements the `BoxOnPlaneSide` operation for `miniquake.render.gl_rmain` (box on plane side).

ParameterTypeDefaultDescription
minsdynamic—The mins input consumed by `BoxOnPlaneSide`.
maxsdynamic—The maxs input consumed by `BoxOnPlaneSide`.
planedynamic—The plane input consumed by `BoxOnPlaneSide`.

View source

c_alias_polys

c_alias_polys

Tracks the module-level c alias polys state owned by `miniquake.render.gl_rmain`.

View source

c_brush_polys

c_brush_polys

Tracks the module-level c brush polys state owned by `miniquake.render.gl_rmain`.

View source

Clear

function Clear(mask)

Implements the `Clear` operation for `miniquake.render.gl_rmain` (clear).

ParameterTypeDefaultDescription
maskdynamic—The mask input consumed by `Clear`.

View source

clearColor

clearColor

Tracks the module-level clear color state owned by `miniquake.render.gl_rmain`.

View source

DepthFunc

function DepthFunc(value)

Implements the `DepthFunc` operation for `miniquake.render.gl_rmain` (depth func).

ParameterTypeDefaultDescription
valuedynamic—Value consumed by `DepthFunc`.

View source

DepthRange

function DepthRange(minimum, maximum)

Implements the `DepthRange` operation for `miniquake.render.gl_rmain` (depth range).

ParameterTypeDefaultDescription
minimumdynamic—Smallest accepted value.
maximumdynamic—Largest accepted value.

View source

Dot

inline function Dot(left, right)

Implements the `Dot` operation for `miniquake.render.gl_rmain` (dot).

ParameterTypeDefaultDescription
leftdynamic—The left input consumed by `Dot`.
rightdynamic—The right input consumed by `Dot`.

View source

F32

function F32(value)

Implements the `F32` operation for `miniquake.render.gl_rmain` (f32).

ParameterTypeDefaultDescription
valuedynamic—Value consumed by `F32`.

View source

frustum

frustum

Tracks the module-level frustum state owned by `miniquake.render.gl_rmain`.

View source

GetFrameState

function GetFrameState()

Return frame state.

View source

GetSinkState

function GetSinkState()

Return sink state.

View source

GL_ALPHA_TEST

GL_ALPHA_TEST

Direct MiniLang pendant of WinQuake/gl_rmain.c. Renderer-owned objects are represented as compact arrays here so the complete original control flow can be executed headlessly by the differential oracle. The live renderer keeps its richer model/entity objects in render/original.ml and render/entities.ml.

View source

GL_BACK

GL_BACK

Tracks the module-level gl back state owned by `miniquake.render.gl_rmain`.

View source

GL_BLEND

GL_BLEND

Tracks the module-level gl blend state owned by `miniquake.render.gl_rmain`.

View source

GL_COLOR_BUFFER_BIT

GL_COLOR_BUFFER_BIT

Tracks the module-level gl color buffer bit state owned by `miniquake.render.gl_rmain`.

View source

GL_CULL_FACE

GL_CULL_FACE

Tracks the module-level gl cull face state owned by `miniquake.render.gl_rmain`.

View source

GL_DEPTH_BUFFER_BIT

GL_DEPTH_BUFFER_BIT

Tracks the module-level gl depth buffer bit state owned by `miniquake.render.gl_rmain`.

View source

GL_DEPTH_TEST

GL_DEPTH_TEST

Tracks the module-level gl depth test state owned by `miniquake.render.gl_rmain`.

View source

GL_DrawAliasFrame

function GL_DrawAliasFrame(header, posenum, light)

Mirror Quake's GL_DrawAliasFrame routine and its observable state changes.

ParameterTypeDefaultDescription
headerdynamic—The header input consumed by `GL_DrawAliasFrame`.
posenumdynamic—The posenum input consumed by `GL_DrawAliasFrame`.
lightdynamic—The light input consumed by `GL_DrawAliasFrame`.

View source

GL_DrawAliasShadow

function GL_DrawAliasShadow(header, posenum, entityOrigin, lightSpot, vector)

Mirror Quake's GL_DrawAliasShadow routine and its observable state changes.

ParameterTypeDefaultDescription
headerdynamic—The header input consumed by `GL_DrawAliasShadow`.
posenumdynamic—The posenum input consumed by `GL_DrawAliasShadow`.
entityOrigindynamic—The entity origin input consumed by `GL_DrawAliasShadow`.
lightSpotdynamic—The light spot input consumed by `GL_DrawAliasShadow`.
vectordynamic—The vector input consumed by `GL_DrawAliasShadow`.

View source

GL_FASTEST

GL_FASTEST

Tracks the module-level gl fastest state owned by `miniquake.render.gl_rmain`.

View source

GL_FLAT

GL_FLAT

Tracks the module-level gl flat state owned by `miniquake.render.gl_rmain`.

View source

GL_FRONT

GL_FRONT

Tracks the module-level gl front state owned by `miniquake.render.gl_rmain`.

View source

GL_GEQUAL

GL_GEQUAL

Tracks the module-level gl gequal state owned by `miniquake.render.gl_rmain`.

View source

GL_LEQUAL

GL_LEQUAL

Tracks the module-level gl lequal state owned by `miniquake.render.gl_rmain`.

View source

GL_MODELVIEW

GL_MODELVIEW

Tracks the module-level gl modelview state owned by `miniquake.render.gl_rmain`.

View source

GL_MODELVIEW_MATRIX

GL_MODELVIEW_MATRIX

Tracks the module-level gl modelview matrix state owned by `miniquake.render.gl_rmain`.

View source

GL_MODULATE

GL_MODULATE

Tracks the module-level gl modulate state owned by `miniquake.render.gl_rmain`.

View source

GL_NICEST

GL_NICEST

Tracks the module-level gl nicest state owned by `miniquake.render.gl_rmain`.

View source

GL_PERSPECTIVE_CORRECTION_HINT

GL_PERSPECTIVE_CORRECTION_HINT

Tracks the module-level gl perspective correction hint state owned by `miniquake.render.gl_rmain`.

View source

GL_PROJECTION

GL_PROJECTION

Tracks the module-level gl projection state owned by `miniquake.render.gl_rmain`.

View source

GL_QUADS

GL_QUADS

Tracks the module-level gl quads state owned by `miniquake.render.gl_rmain`.

View source

GL_REPLACE

GL_REPLACE

Tracks the module-level gl replace state owned by `miniquake.render.gl_rmain`.

View source

GL_SMOOTH

GL_SMOOTH

Tracks the module-level gl smooth state owned by `miniquake.render.gl_rmain`.

View source

GL_TEXTURE_2D

GL_TEXTURE_2D

Tracks the module-level gl texture 2 d state owned by `miniquake.render.gl_rmain`.

View source

GL_TEXTURE_ENV

GL_TEXTURE_ENV

Tracks the module-level gl texture env state owned by `miniquake.render.gl_rmain`.

View source

GL_TEXTURE_ENV_MODE

GL_TEXTURE_ENV_MODE

Tracks the module-level gl texture env mode state owned by `miniquake.render.gl_rmain`.

View source

GL_TRIANGLE_STRIP

GL_TRIANGLE_STRIP

Tracks the module-level gl triangle strip state owned by `miniquake.render.gl_rmain`.

View source

gldepthmax

gldepthmax

Tracks the module-level gldepthmax state owned by `miniquake.render.gl_rmain`.

View source

gldepthmin

gldepthmin

Tracks the module-level gldepthmin state owned by `miniquake.render.gl_rmain`.

View source

lastposenum

lastposenum

Tracks the module-level lastposenum state owned by `miniquake.render.gl_rmain`.

View source

MakeAliasHeader

function MakeAliasHeader()

Create and initialize alias header.

View source

mirror

mirror

Tracks the module-level mirror state owned by `miniquake.render.gl_rmain`.

View source

mirrorAlpha

mirrorAlpha

Tracks the module-level mirror alpha state owned by `miniquake.render.gl_rmain`.

View source

mirrorPlane

mirrorPlane

Tracks the module-level mirror plane state owned by `miniquake.render.gl_rmain`.

View source

MultiplyAdd

function MultiplyAdd(origin, scale, direction)

Implements the `MultiplyAdd` operation for `miniquake.render.gl_rmain` (multiply add).

ParameterTypeDefaultDescription
origindynamic—World-space origin of the operation.
scaledynamic—The scale input consumed by `MultiplyAdd`.
directiondynamic—The direction input consumed by `MultiplyAdd`.

View source

MYgluPerspective

function MYgluPerspective(fovy, aspect, zNear, zFar)

Implements the `MYgluPerspective` operation for `miniquake.render.gl_rmain` (m yglu perspective).

ParameterTypeDefaultDescription
fovydynamic—The fovy input consumed by `MYgluPerspective`.
aspectdynamic—The aspect input consumed by `MYgluPerspective`.
zNeardynamic—The z near input consumed by `MYgluPerspective`.
zFardynamic—The z far input consumed by `MYgluPerspective`.

View source

Note

function Note(operation, a, b, c, d)

Implements the `Note` operation for `miniquake.render.gl_rmain` (note).

ParameterTypeDefaultDescription
operationdynamic—The operation input consumed by `Note`.
adynamic—The a input consumed by `Note`.
bdynamic—The b input consumed by `Note`.
cdynamic—The c input consumed by `Note`.
ddynamic—The d input consumed by `Note`.

View source

PrepareWorld

function PrepareWorld()

Implements the `PrepareWorld` operation for `miniquake.render.gl_rmain` (prepare world).

View source

R_Clear

function R_Clear()

Apply the Quake-compatible r clear behavior.

View source

R_CullBox

function R_CullBox(mins, maxs)

Apply the Quake-compatible r cull box behavior.

ParameterTypeDefaultDescription
minsdynamic—The mins input consumed by `R_CullBox`.
maxsdynamic—The maxs input consumed by `R_CullBox`.

View source

R_DrawAliasModel

function R_DrawAliasModel(entity, header, time, shadows)

Apply the Quake-compatible r draw alias model behavior.

ParameterTypeDefaultDescription
entitydynamic—Entity affected by the operation.
headerdynamic—The header input consumed by `R_DrawAliasModel`.
timedynamic—Simulation or presentation time for the operation.
shadowsdynamic—The shadows input consumed by `R_DrawAliasModel`.

View source

r_drawentities

r_drawentities

Tracks the module-level r drawentities state owned by `miniquake.render.gl_rmain`.

View source

R_DrawEntitiesOnList

function R_DrawEntitiesOnList(brushCount, sprites)

Apply the Quake-compatible r draw entities on list behavior.

ParameterTypeDefaultDescription
brushCountdynamic—Number of entries or units to process.
spritesdynamic—The sprites input consumed by `R_DrawEntitiesOnList`.

View source

R_DrawSpriteModel

function R_DrawSpriteModel(entity, frame)

Apply the Quake-compatible r draw sprite model behavior.

ParameterTypeDefaultDescription
entitydynamic—Entity affected by the operation.
framedynamic—The frame input consumed by `R_DrawSpriteModel`.

View source

R_DrawViewModel

function R_DrawViewModel(entity, header, time, shadows)

Apply the Quake-compatible r draw view model behavior.

ParameterTypeDefaultDescription
entitydynamic—Entity affected by the operation.
headerdynamic—The header input consumed by `R_DrawViewModel`.
timedynamic—Simulation or presentation time for the operation.
shadowsdynamic—The shadows input consumed by `R_DrawViewModel`.

View source

r_drawviewmodel

r_drawviewmodel

Tracks the module-level r drawviewmodel state owned by `miniquake.render.gl_rmain`.

View source

r_fov_x

r_fov_x

Tracks the module-level r fov x state owned by `miniquake.render.gl_rmain`.

View source

r_fov_y

r_fov_y

Tracks the module-level r fov y state owned by `miniquake.render.gl_rmain`.

View source

r_framecount

r_framecount

Tracks the module-level r framecount state owned by `miniquake.render.gl_rmain`.

View source

R_GetSpriteFrame

function R_GetSpriteFrame(frameType, textures, intervals, time, syncbase)

Apply the Quake-compatible r get sprite frame behavior.

ParameterTypeDefaultDescription
frameTypedynamic—The frame type input consumed by `R_GetSpriteFrame`.
texturesdynamic—The textures input consumed by `R_GetSpriteFrame`.
intervalsdynamic—The intervals input consumed by `R_GetSpriteFrame`.
timedynamic—Simulation or presentation time for the operation.
syncbasedynamic—The syncbase input consumed by `R_GetSpriteFrame`.

View source

R_Mirror

function R_Mirror()

Apply the Quake-compatible r mirror behavior.

View source

r_origin

r_origin

Tracks the module-level r origin state owned by `miniquake.render.gl_rmain`.

View source

R_PolyBlend

function R_PolyBlend()

Apply the Quake-compatible r poly blend behavior.

View source

R_RenderScene

function R_RenderScene()

Apply the Quake-compatible r render scene behavior.

View source

R_RenderView

function R_RenderView()

Apply the Quake-compatible r render view behavior.

View source

R_RotateForEntity

function R_RotateForEntity(entity)

Apply the Quake-compatible r rotate for entity behavior.

ParameterTypeDefaultDescription
entitydynamic—Entity affected by the operation.

View source

R_SetFrustum

function R_SetFrustum()

Apply the Quake-compatible r set frustum behavior.

View source

R_SetupAliasFrame

function R_SetupAliasFrame(frame, header, time, light)

Apply the Quake-compatible r setup alias frame behavior.

ParameterTypeDefaultDescription
framedynamic—The frame input consumed by `R_SetupAliasFrame`.
headerdynamic—The header input consumed by `R_SetupAliasFrame`.
timedynamic—Simulation or presentation time for the operation.
lightdynamic—The light input consumed by `R_SetupAliasFrame`.

View source

R_SetupFrame

function R_SetupFrame()

Apply the Quake-compatible r setup frame behavior.

View source

R_SetupGL

function R_SetupGL()

Apply the Quake-compatible r setup gl behavior.

View source

r_viewangles

r_viewangles

Tracks the module-level r viewangles state owned by `miniquake.render.gl_rmain`.

View source

r_vieworg

r_vieworg

Tracks the module-level r vieworg state owned by `miniquake.render.gl_rmain`.

View source

ResetCompatibility

function ResetCompatibility()

Update module state for compatibility.

View source

ResetSink

function ResetSink()

Update module state for sink.

View source

SetBlend

function SetBlend(value)

Update module state for blend.

ParameterTypeDefaultDescription
valuedynamic—Value consumed by `SetBlend`.

View source

SetClearFlags

function SetClearFlags(alpha, clearValue, zValue)

Update module state for clear flags.

ParameterTypeDefaultDescription
alphadynamic—The alpha input consumed by `SetClearFlags`.
clearValuedynamic—The clear value input consumed by `SetClearFlags`.
zValuedynamic—The z value input consumed by `SetClearFlags`.

View source

SetCullPlanes

function SetCullPlanes(planes)

Update module state for cull planes.

ParameterTypeDefaultDescription
planesdynamic—The planes input consumed by `SetCullPlanes`.

View source

SetDepthCompatibility

function SetDepthCompatibility(minimum, maximum)

Update module state for depth compatibility.

ParameterTypeDefaultDescription
minimumdynamic—Smallest accepted value.
maximumdynamic—Largest accepted value.

View source

SetDrawFlags

function SetDrawFlags(entities, viewModel)

Update module state for draw flags.

ParameterTypeDefaultDescription
entitiesdynamic—The entities input consumed by `SetDrawFlags`.
viewModeldynamic—The view model input consumed by `SetDrawFlags`.

View source

SetFrameState

function SetFrameState(frame, brushPolys, aliasPolys)

Update module state for frame state.

ParameterTypeDefaultDescription
framedynamic—The frame input consumed by `SetFrameState`.
brushPolysdynamic—The brush polys input consumed by `SetFrameState`.
aliasPolysdynamic—The alias polys input consumed by `SetFrameState`.

View source

SetMirror

function SetMirror(value, plane)

Update module state for mirror.

ParameterTypeDefaultDescription
valuedynamic—Value consumed by `SetMirror`.
planedynamic—The plane input consumed by `SetMirror`.

View source

SetViewBasis

function SetViewBasis(origin, forward, right, up)

Update module state for view basis.

ParameterTypeDefaultDescription
origindynamic—World-space origin of the operation.
forwarddynamic—The forward input consumed by `SetViewBasis`.
rightdynamic—The right input consumed by `SetViewBasis`.
updynamic—The up input consumed by `SetViewBasis`.

View source

SignbitsForPlane

function SignbitsForPlane(plane)

Implements the `SignbitsForPlane` operation for `miniquake.render.gl_rmain` (signbits for plane).

ParameterTypeDefaultDescription
planedynamic—The plane input consumed by `SignbitsForPlane`.

View source

sinkBinds

sinkBinds

Tracks the module-level sink binds state owned by `miniquake.render.gl_rmain`.

View source

sinkCalls

sinkCalls

Tracks the module-level sink calls state owned by `miniquake.render.gl_rmain`.

View source

sinkClearMask

sinkClearMask

Tracks the module-level sink clear mask state owned by `miniquake.render.gl_rmain`.

View source

sinkDepthFunc

sinkDepthFunc

Tracks the module-level sink depth func state owned by `miniquake.render.gl_rmain`.

View source

sinkDepthMax

sinkDepthMax

Tracks the module-level sink depth max state owned by `miniquake.render.gl_rmain`.

View source

sinkDepthMin

sinkDepthMin

Tracks the module-level sink depth min state owned by `miniquake.render.gl_rmain`.

View source

sinkHash

sinkHash

Tracks the module-level sink hash state owned by `miniquake.render.gl_rmain`.

View source

sinkLastTexture

sinkLastTexture

Tracks the module-level sink last texture state owned by `miniquake.render.gl_rmain`.

View source

sinkScalar

sinkScalar

Tracks the module-level sink scalar state owned by `miniquake.render.gl_rmain`.

View source

sinkVertices

sinkVertices

Tracks the module-level sink vertices state owned by `miniquake.render.gl_rmain`.

View source

Subtract

function Subtract(left, right)

Implements the `Subtract` operation for `miniquake.render.gl_rmain` (subtract).

ParameterTypeDefaultDescription
leftdynamic—The left input consumed by `Subtract`.
rightdynamic—The right input consumed by `Subtract`.

View source

trickFrame

trickFrame

Tracks the module-level trick frame state owned by `miniquake.render.gl_rmain`.

View source

Vertex

function Vertex(operation, point)

Implements the `Vertex` operation for `miniquake.render.gl_rmain` (vertex).

ParameterTypeDefaultDescription
operationdynamic—The operation input consumed by `Vertex`.
pointdynamic—The point input consumed by `Vertex`.

View source

vpn

vpn

Tracks the module-level vpn state owned by `miniquake.render.gl_rmain`.

View source

vright

vright

Tracks the module-level vright state owned by `miniquake.render.gl_rmain`.

View source

vup

vup

Tracks the module-level vup state owned by `miniquake.render.gl_rmain`.

View source

zTrick

zTrick

Tracks the module-level z trick state owned by `miniquake.render.gl_rmain`.

View source