summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/glide/fxsetup.c
diff options
context:
space:
mode:
authorDaniel Borca <dborca@users.sourceforge.net>2003-11-03 12:01:03 +0000
committerDaniel Borca <dborca@users.sourceforge.net>2003-11-03 12:01:03 +0000
commit313e12e05843dadb12a3a53d2dd161478c9b3202 (patch)
tree83cef18b4fcf383803b3a60d3902832e146deb7d /src/mesa/drivers/glide/fxsetup.c
parent7093114285bb315070af572ff4aecc204c400ef4 (diff)
Voodoo2 happiness
Diffstat (limited to 'src/mesa/drivers/glide/fxsetup.c')
-rw-r--r--src/mesa/drivers/glide/fxsetup.c33
1 files changed, 17 insertions, 16 deletions
diff --git a/src/mesa/drivers/glide/fxsetup.c b/src/mesa/drivers/glide/fxsetup.c
index 6e929257db..22c34cecaf 100644
--- a/src/mesa/drivers/glide/fxsetup.c
+++ b/src/mesa/drivers/glide/fxsetup.c
@@ -803,33 +803,27 @@ fxSetupDoubleTMU_NoLock(fxMesaContext fxMesa,
}
}
+ /* [dBorca] Hack alert:
+ * we put these in reverse order, so that if we can't
+ * do _REAL_ pointcast, the TMU0 table gets broadcasted
+ */
if (!fxMesa->haveGlobalPaletteTexture) {
/* pointcast */
- if (ti0->info.format == GR_TEXFMT_P_8) {
- if (TDFX_DEBUG & VERBOSE_DRIVER) {
- fprintf(stderr, "%s: uploading texture palette for TMU0\n", __FUNCTION__);
- }
- fxMesa->Glide.grTexDownloadTableExt(ti0->whichTMU, ti0->paltype, &(ti0->palette));
- }
-#if 1
- else /* does anyone guess why is this here? :D */
-#endif
if (ti1->info.format == GR_TEXFMT_P_8) {
if (TDFX_DEBUG & VERBOSE_DRIVER) {
fprintf(stderr, "%s: uploading texture palette for TMU1\n", __FUNCTION__);
}
fxMesa->Glide.grTexDownloadTableExt(ti1->whichTMU, ti1->paltype, &(ti1->palette));
}
+ if (ti0->info.format == GR_TEXFMT_P_8) {
+ if (TDFX_DEBUG & VERBOSE_DRIVER) {
+ fprintf(stderr, "%s: uploading texture palette for TMU0\n", __FUNCTION__);
+ }
+ fxMesa->Glide.grTexDownloadTableExt(ti0->whichTMU, ti0->paltype, &(ti0->palette));
+ }
}
#if FX_TC_NCC
/* pointcast */
- if ((ti0->info.format == GR_TEXFMT_AYIQ_8422) ||
- (ti0->info.format == GR_TEXFMT_YIQ_422)) {
- if (TDFX_DEBUG & VERBOSE_DRIVER) {
- fprintf(stderr, "%s: uploading NCC0 table for TMU0\n", __FUNCTION__);
- }
- fxMesa->Glide.grTexDownloadTableExt(ti0->whichTMU, GR_TEXTABLE_NCC0, &(ti0->palette));
- }
if ((ti1->info.format == GR_TEXFMT_AYIQ_8422) ||
(ti1->info.format == GR_TEXFMT_YIQ_422)) {
if (TDFX_DEBUG & VERBOSE_DRIVER) {
@@ -837,6 +831,13 @@ fxSetupDoubleTMU_NoLock(fxMesaContext fxMesa,
}
fxMesa->Glide.grTexDownloadTableExt(ti1->whichTMU, GR_TEXTABLE_NCC0, &(ti1->palette));
}
+ if ((ti0->info.format == GR_TEXFMT_AYIQ_8422) ||
+ (ti0->info.format == GR_TEXFMT_YIQ_422)) {
+ if (TDFX_DEBUG & VERBOSE_DRIVER) {
+ fprintf(stderr, "%s: uploading NCC0 table for TMU0\n", __FUNCTION__);
+ }
+ fxMesa->Glide.grTexDownloadTableExt(ti0->whichTMU, GR_TEXTABLE_NCC0, &(ti0->palette));
+ }
#endif
grTexSource(tmu0, ti0->tm[tmu0]->startAddr,