From 5566127701df5c97aca94dd99b066f94943ea969 Mon Sep 17 00:00:00 2001 From: Felix Kuehling Date: Wed, 15 Dec 2004 16:59:58 +0000 Subject: Fixed GL_CLAM_TO_EDGE. It's not supported in hardware. Use GL_CLAMP instead of GL_REPEAT. --- src/mesa/drivers/dri/savage/savagetex.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/drivers/dri/savage/savagetex.c b/src/mesa/drivers/dri/savage/savagetex.c index 9c5b376d71..edb016f152 100644 --- a/src/mesa/drivers/dri/savage/savagetex.c +++ b/src/mesa/drivers/dri/savage/savagetex.c @@ -1020,8 +1020,10 @@ static void savageUpdateTex0State_s4( GLcontext *ctx ) break; } - imesa->regs.s4.texCtrl[0].ni.uMode = !(t->texParams.sWrapMode & 0x01); - imesa->regs.s4.texCtrl[0].ni.vMode = !(t->texParams.tWrapMode & 0x01); + imesa->regs.s4.texCtrl[0].ni.uMode = + t->texParams.sWrapMode == GL_REPEAT ? 0 : 1; + imesa->regs.s4.texCtrl[0].ni.vMode = + t->texParams.tWrapMode == GL_REPEAT ? 0 : 1; switch (t->texParams.minFilter) { @@ -1222,8 +1224,10 @@ static void savageUpdateTex1State_s4( GLcontext *ctx ) break; } - imesa->regs.s4.texCtrl[1].ni.uMode = !(t->texParams.sWrapMode & 0x01); - imesa->regs.s4.texCtrl[1].ni.vMode = !(t->texParams.tWrapMode & 0x01); + imesa->regs.s4.texCtrl[1].ni.uMode = + t->texParams.sWrapMode == GL_REPEAT ? 0 : 1; + imesa->regs.s4.texCtrl[1].ni.vMode = + t->texParams.tWrapMode == GL_REPEAT ? 0 : 1; switch (t->texParams.minFilter) { -- cgit v1.2.3