#
inner
fxAADrawTriangle(a, b, c, b1, b2, b3)
draw an anti-aliased triangle
Parameters:
Name
Type
Description
a
Array.<number>
a vertex
b
Array.<number>
a vertex
c
Array.<number>
a vertex
b1
boolean
anti alias AB edge
b2
boolean
anti alias BC edge
b3
boolean
anti alias CA edge
View Source
doc/internal.js , line 1078
#
inner
fxAlphaBlendFunction(rgb_sf, rgb_df, alpha_sf, alpha_df)
specify the alpha blending function
Parameters:
Name
Type
Description
rgb_sf
GR_BLEND
rgb source blending factor
rgb_df
GR_BLEND
rgb destination blending factor
alpha_sf
GR_BLEND
alpha source blending factor
alpha_df
GR_BLEND
alpha destination blending factor
View Source
doc/internal.js , line 1010
#
inner
fxAlphaCombine(func, factor, local, other, invert)
configure the alpha combine unit.
Parameters:
Name
Type
Description
func
GR_COMBINE_FUNCTION
function
factor
GR_COMBINE_FACTOR
scaling factor
local
GR_COMBINE_LOCAL
local alpha
other
GR_COMBINE_OTHER
other alpha
invert
boolean
invert generated alpha.
View Source
doc/internal.js , line 1020
#
inner
fxAlphaControlsITRGBLighting(enable)
enables/disables alpha controlled lighting
Parameters:
Name
Type
Description
enable
boolean
enable/disable
View Source
doc/internal.js , line 1090
#
inner
fxAlphaTestReferenceValue(value)
specify the alpha test reference value
Parameters:
Name
Type
Description
value
number
The new alpha test reference value.
View Source
doc/internal.js , line 1208
#
inner
FXBIT(i) → {number}
set a bit.
Parameters:
Name
Type
Description
i
number
bit to set.
View Source
jsboot/3dfx.js , line 11
Returns:
number with given bit set.
Type:
number
#
inner
fxBufferClear(color, alpha, depth)
clear the buffers to the specified values
Parameters:
Name
Type
Description
color
number
The color value used for clearing the draw buffer.
alpha
number
The alpha value used for clearing the alpha buffer
depth
number
An unsigned value used for clearing the depth buffer
View Source
doc/internal.js , line 959
#
inner
fxBufferSwap(interval)
exchange front and back buffers
Parameters:
Name
Type
Description
interval
number
The number of vertical retraces to wait before swapping the front and back buffers.
View Source
doc/internal.js , line 951
#
inner
fxChromakeyValue(val)
set the global chroma-key reference value
Parameters:
Name
Type
Description
val
number
The new chroma-key reference value.
View Source
doc/internal.js , line 1196
#
inner
fxClipWindow(minx, miny, maxx, maxy)
set the size and location of the hardware clipping window
Parameters:
Name
Type
Description
minx
number
The lower x screen coordinate of the clipping window.
miny
number
The lower y screen coordinate of the clipping window.
maxx
number
The upper x screen coordinate of the clipping window.
maxy
number
The upper y screen coordinate of the clipping window.
View Source
doc/internal.js , line 968
#
inner
fxColorCombine(func, factor, local, other, invert)
configure the color combine unit.
Parameters:
Name
Type
Description
func
GR_COMBINE_FUNCTION
function
factor
GR_COMBINE_FACTOR
scaling factor
local
GR_COMBINE_LOCAL
local alpha
other
GR_COMBINE_OTHER
other alpha
invert
boolean
invert generated alpha.
View Source
doc/internal.js , line 1030
#
inner
fxColorMask(rgb, alpha)
enable/disable writing into the color and alpha buffers
Parameters:
Name
Type
Description
rgb
number
color mask
alpha
number
alpha mask
View Source
doc/internal.js , line 1037
#
inner
fxDepthBufferFunction(func)
specify the depth buffer comparison function
Parameters:
Name
Type
Description
func
GR_CMP
the new function
View Source
doc/internal.js , line 1116
#
inner
fxDrawLine(v1, v2)
draw a one-pixel-wide arbitrarily oriented line
Parameters:
Name
Type
Description
v1
Array.<number>
a vertex.
v2
Array.<number>
a vertex.
View Source
doc/internal.js , line 981
#
inner
fxDrawTriangle(v1, v2, v3)
draw a triangle
Parameters:
Name
Type
Description
v1
Array.<number>
a vertex.
v2
Array.<number>
a vertex.
v3
Array.<number>
a vertex.
View Source
doc/internal.js , line 989
#
inner
fxDrawVertexArray(mode, vertices)
draw a list of by-vertex vertices
Parameters:
Name
Type
Description
mode
GR_VERTEX
vertex type
vertices
Array.<Array.<number>>
array of vertices.
View Source
doc/internal.js , line 1050
#
inner
fxFogGenerateExp(density) → {Array.<number>}
generate an exponential fog table
Parameters:
Name
Type
Description
density
number
The fog density, typically between 0.0 and 1.0.
View Source
doc/internal.js , line 1169
Returns:
a fog table.
Type:
Array.<number>
#
inner
fxFogGenerateExp2(density) → {Array.<number>}
generate an exponential squared fog table
Parameters:
Name
Type
Description
density
*
The fog density, typically between 0.0 and 1.0.
View Source
doc/internal.js , line 1176
Returns:
a fog table.
Type:
Array.<number>
#
inner
fxFogGenerateLinear(near, far) → {Array.<number>}
generate a linear fog table
Parameters:
Name
Type
Description
near
number
The eye-space w coordinate where minimum fog exists.
far
number
The eye-space w coordinate where maximum fog exists.
View Source
doc/internal.js , line 1184
Returns:
a fog table.
Type:
Array.<number>
#
inner
fxFogTable(table)
download a fog table
Parameters:
Name
Type
Description
table
Array.<number>
a new table with at least fxGetFogTableEntries() entries
View Source
doc/internal.js , line 1162
#
inner
fxFogTableIndexToW(i)
convert a fog table index to a floating point eye-space w value
Parameters:
Name
Type
Description
i
number
The fog table index, between 0 and GR_FOG_TABLE_SIZE.
View Source
doc/internal.js , line 1156
#
inner
fxGetGammaTableEntries() → {number}
View Source
doc/internal.js , line 1317
Returns:
The number of entries in the hardware gamma table. Returns FXFALSE if it is not possible to manipulate gamma (e.g. on a Macronix card, or in windowed mode).
Type:
number
#
inner
fxGetMaxTextureAspectRatio() → {number}
View Source
doc/internal.js , line 1341
Returns:
The logarithm base 2 of the maximum aspect ratio supported for power-of-two, mipmap-able textures (e.g. Voodoo Graphics returns 3).
Type:
number
#
inner
fxGetMaxTextureSize() → {number}
View Source
doc/internal.js , line 1337
Returns:
The width of the largest texture supported on this configuration (e.g. Voodoo Graphics returns 256).
Type:
number
#
inner
fxGetMemoryFb() → {number}
View Source
doc/internal.js , line 1325
Returns:
The total number of bytes per Pixelfx chip if a non-UMA configuration is used, else 0. In non-UMA configurations, the total FB memory is GR_MEMORY_FB * GR_NUM_FB.
Type:
number
#
inner
fxGetMemoryTMU() → {number}
View Source
doc/internal.js , line 1329
Returns:
The total number of bytes per Texelfx chip if a non-UMA configuration is used, else FXFALSE. In non-UMA configurations, the total usable texture memory is GR_MEMORY_TMU * GR_NUM_TMU.
Type:
number
#
inner
fxGetNumFb() → {number}
View Source
doc/internal.js , line 1349
Returns:
The number of Pixelfx chips present. This number will always be 1 except for SLI configurations.
Type:
number
#
inner
fxGetNumTmu() → {number}
View Source
doc/internal.js , line 1353
Returns:
The number of Texelfx chips per Pixelfx chip. For integrated chips, the number of TMUs will be returned.
Type:
number
#
inner
fxInit()
init 3dfx glide.
the following parameters are used:
GR_RESOLUTION_640x480,
GR_REFRESH_60Hz,
GR_COLORFORMAT_ARGB,
GR_ORIGIN_UPPER_LEFT,
GR_WINDOW_COORDS
View Source
doc/internal.js , line 914
#
inner
fxLfbConstantAlpha(val)
Alpha value to use for direct framebuffer access.
Parameters:
Name
Type
Description
val
number
the constant alpha value.
View Source
doc/internal.js , line 1372
#
inner
fxLfbConstantDepth(val)
Depth value to use for direct framebuffer access.
Parameters:
Name
Type
Description
val
number
the constant depth value.
View Source
doc/internal.js , line 1379
#
inner
fxRenderBuffer(buffer)
selects the current color buffer for drawing and clearing
Parameters:
Name
Type
Description
buffer
GR_BUFFER
Selects the current color buffer. Valid values are GR_BUFFER_FRONTBUFFER and GR_BUFFER_BACKBUFFER.
View Source
doc/internal.js , line 1277
#
inner
FxRGB2Vertex(v, idx, rgb)
split up RGB value and store in vertex.
Parameters:
Name
Type
Description
v
Array.<number>
the vertex to store in.
idx
number
start index of RGB values.
rgb
number
the RGB value.
View Source
jsboot/3dfx.js , line 616
#
inner
fxTexCalcMemRequired(smallLod, largeLod, aspect, format) → {number}
return the texture memory consumed by a texture.
Parameters:
Name
Type
Description
smallLod
GR_LOD
smallest level of detail
largeLod
GR_LOD
larges level of detail
aspect
GR_ASPECT
texture aspect ratio
format
GR_TEXFMT
texture format
View Source
doc/internal.js , line 1271
Returns:
number of bytes required
Type:
number
#
inner
fxTexClampMode(tmu, sMode, tMode)
set the texture map clamping/wrapping mode
Parameters:
Name
Type
Description
tmu
GR_TMU
the TMU.
sMode
GR_TEXTURECLAMP
The new mode for the s direction
tMode
GR_TEXTURECLAMP
The new mode for the t direction
View Source
doc/internal.js , line 1224
#
inner
fxTexCombine(tmu, rgb_func, rgb_factor, alpha_func, alpha_factor, rgb_invert, alpha_invert)
configure a texture combine unit
Parameters:
Name
Type
Description
tmu
GR_TMU
the TMU.
rgb_func
GR_COMBINE_FUNCTION
Specifies the function used in texture color generation
rgb_factor
GR_COMBINE_FACTOR
Specifies the scaling factor f used in texture color generation
alpha_func
GR_COMBINE_FUNCTION
Specifies the function used in texture alpha generation
alpha_factor
GR_COMBINE_FACTOR
Specifies the scaling factor f used in texture alpha generation
rgb_invert
boolean
Specifies whether the generated texture color should be bitwise inverted as a final step.
alpha_invert
boolean
Specifies whether the generated texture alpha should be bitwise inverted as a final step.
View Source
doc/internal.js , line 1251
#
inner
fxTexDetailControl(tmu, lodBias, detailScale, detailMax)
set the detail texturing controls
Parameters:
Name
Type
Description
tmu
GR_TMU
the TMU.
lodBias
number
Controls where the blending between the two textures begins. This value is an LOD bias value in the range [–32.. +31].
detailScale
number
Controls the steepness of the blend. Values are in the range [0..7] are valid. The scale is computed as 2^detailScale.
detailMax
number
Controls the maximum blending that occurs. Values in the range [0.0..1.0] are valid.
View Source
doc/internal.js , line 1260
#
inner
fxTexFilterMode(tmu, minFilter, magFilter)
specify the texture minification and magnification filters
Parameters:
Name
Type
Description
tmu
GR_TMU
the TMU.
minFilter
GR_TEXTUREFILTER
The minification filter
magFilter
GR_TEXTUREFILTER
The magnification filter
View Source
doc/internal.js , line 1216
#
inner
fxTexLodBiasValue(tmu, bias)
set the LOD bias value
Parameters:
Name
Type
Description
tmu
GR_TMU
the TMU.
bias
number
The new LOD bias value, a signed floating point value in the range [-8..7.75].
View Source
doc/internal.js , line 1239
#
inner
FxTexMemGetStartAddress(tmu, info) → {number}
try to find the next available memory for texture.
Parameters:
Name
Type
Description
tmu
GR_TMU
the TMU where this texture shall be used.
info
TexInfo
the texture.
View Source
jsboot/3dfx.js , line 579
Returns:
a start address or null.
Type:
number
#
inner
FxTexMemInit(tmu)
(re)initialize simple texture memory management for given TMU.
Parameters:
Name
Type
Description
tmu
GR_TMU
the tmu to initialize.
View Source
jsboot/3dfx.js , line 564
#
inner
fxTexMipMapMode(tmu, mode, lodBlend)
set the mipmapping mode
Parameters:
Name
Type
Description
tmu
GR_TMU
the TMU.
mode
GR_MIPMAP
The new mipmapping mode
lodBlend
boolean
enables/disables LOD blending
View Source
doc/internal.js , line 1232
#
inner
fxTexNCCTable(table)
select an NCC table
Parameters:
Name
Type
Description
table
GR_TEXTABLE
NCC table to use for decompressing compressed textures. Valid values are GR_TEXTABLE_NCC0 and GR_TEXTABLE_NCC1.
View Source
doc/internal.js , line 1295
#
inner
fxVertexLayout(layout)
specify the format of by-vertex arrays
Parameters:
Name
Type
Description
layout
Array.<GR_PARAM>
list of layout parameters.
View Source
doc/internal.js , line 935
#
inner
fxViewport(x, y, width, height)
define a viewport
Parameters:
Name
Type
Description
x
number
The origin of the viewport, relative to the screen origin
y
number
The origin of the viewport, relative to the screen origin
width
number
The width and height of the viewport.
height
number
The width and height of the viewport.
View Source
doc/internal.js , line 1138