diff options
author | Brian Paul <[email protected]> | 2000-03-03 17:53:26 +0000 |
---|---|---|
committer | Brian Paul <[email protected]> | 2000-03-03 17:53:26 +0000 |
commit | 4f980f4ebb0fc9ec9032a31d54cc1fd745359e0b (patch) | |
tree | 2baa0941e41b21e1f5abfd01438fa9717e5187f1 /src/mesa/drivers/glide/fxapi.c | |
parent | b440dfeee6a8823c685cfd5a0e505ce163a0d2d3 (diff) |
depth buffer change, BGR/RGB setup change
Diffstat (limited to 'src/mesa/drivers/glide/fxapi.c')
-rw-r--r-- | src/mesa/drivers/glide/fxapi.c | 22 |
1 files changed, 18 insertions, 4 deletions
diff --git a/src/mesa/drivers/glide/fxapi.c b/src/mesa/drivers/glide/fxapi.c index 0b96cf4399a..2465ce37bc9 100644 --- a/src/mesa/drivers/glide/fxapi.c +++ b/src/mesa/drivers/glide/fxapi.c @@ -696,6 +696,8 @@ void GLAPIENTRY fxMesaSetNearFar(GLfloat n, GLfloat f) /* * The extension GL_FXMESA_global_texture_lod_bias */ +/* XXX this function may soon go away in favor of GL_EXT_texture_lod_bias */ +extern void GLAPIENTRY glGlobalTextureLODBiasFXMESA(GLfloat biasVal); void GLAPIENTRY glGlobalTextureLODBiasFXMESA(GLfloat biasVal) { grTexLodBiasValue(GR_TMU0,biasVal); @@ -710,6 +712,7 @@ void GLAPIENTRY glGlobalTextureLODBiasFXMESA(GLfloat biasVal) * More a trick than a real extesion, use the shared global * palette extension. */ +extern void GLAPIENTRY gl3DfxSetPaletteEXT(GLuint *pal); /* silence warning */ void GLAPIENTRY gl3DfxSetPaletteEXT(GLuint *pal) { fxMesaContext fxMesa =fxMesaCurrentCtx; @@ -890,8 +893,10 @@ fxMesaContext GLAPIENTRY fxMesaCreateContext(GLuint win, case FXMESA_DEPTH_SIZE: i++; depthSize=attribList[i]; - if(depthSize) + if(depthSize) { aux=1; + depthSize = 16; + } break; case FXMESA_STENCIL_SIZE: i++; @@ -982,11 +987,20 @@ fxMesaContext GLAPIENTRY fxMesaCreateContext(GLuint win, * as Voodoo3s have 2 TMUs on board, Banshee has only 1 * Thanks to Joseph Kain for that one */ - if (glbHWConfig.SSTs[glbCurrentBoard].sstBoard.VoodooConfig.nTexelfx == 2) { - fxInitPixelTables(fxMesa, GL_FALSE); /* use RGB pixel order (Voodoo3) */ + GrVoodooConfig_t *voodoo; + voodoo = &glbHWConfig.SSTs[glbCurrentBoard].sstBoard.VoodooConfig; + + printf("nTexelfx %d\n", voodoo->nTexelfx); + printf("fbRam %d\n", voodoo->fbRam); + printf("fbiRev %d\n", voodoo->fbiRev); + + if (voodoo->nTexelfx == 2 && voodoo->fbiRev != 260) { + /* RGB pixel order (Voodoo3, but some Quantum3D models) */ + fxInitPixelTables(fxMesa, GL_FALSE); } else { - fxInitPixelTables(fxMesa, GL_TRUE); /* use BGR pixel order on Voodoo1/2 */ + /* BGR pixel order on Voodoo1/2, or certain Quantum3D models */ + fxInitPixelTables(fxMesa, GL_TRUE); } } else { |