diff options
author | Keith Whitwell <[email protected]> | 2004-12-30 14:21:46 +0000 |
---|---|---|
committer | Keith Whitwell <[email protected]> | 2004-12-30 14:21:46 +0000 |
commit | 6fcc6c49654d9e87fbcadba14bc2f45e9bdbf8f7 (patch) | |
tree | c8c8892ef035e42c0d57609008eedbe7475df5e3 /src/mesa | |
parent | bcd1a9ed68cee96022af0816a1d22de86691fc77 (diff) |
Fix MagFilter state for texunit 0
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/drivers/dri/unichrome/via_state.c | 28 |
1 files changed, 17 insertions, 11 deletions
diff --git a/src/mesa/drivers/dri/unichrome/via_state.c b/src/mesa/drivers/dri/unichrome/via_state.c index 547bf8b7ff7..08056106140 100644 --- a/src/mesa/drivers/dri/unichrome/via_state.c +++ b/src/mesa/drivers/dri/unichrome/via_state.c @@ -864,13 +864,17 @@ static void viaChooseTextureState(GLcontext *ctx) break; } - if (texObj->MagFilter) { + switch (texObj->MagFilter) { + case GL_LINEAR: vmesa->regHTXnTB_0 |= HC_HTXnFLSe_Linear | HC_HTXnFLTe_Linear; - } - else { + break; + case GL_NEAREST: vmesa->regHTXnTB_0 |= HC_HTXnFLSe_Nearest | HC_HTXnFLTe_Nearest; + break; + default: + break; } vmesa->regHTXnMPMD_0 &= ~(HC_HTXnMPMD_SMASK | HC_HTXnMPMD_TMASK); @@ -928,14 +932,16 @@ static void viaChooseTextureState(GLcontext *ctx) } switch(texObj->MagFilter) { - case GL_NEAREST: - vmesa->regHTXnTB_1 |= HC_HTXnFLSs_Nearest | - HC_HTXnFLTs_Nearest; - break; - case GL_LINEAR: - vmesa->regHTXnTB_1 |= HC_HTXnFLSs_Linear | - HC_HTXnFLTs_Linear; - break; + case GL_NEAREST: + vmesa->regHTXnTB_1 |= HC_HTXnFLSs_Nearest | + HC_HTXnFLTs_Nearest; + break; + case GL_LINEAR: + vmesa->regHTXnTB_1 |= HC_HTXnFLSs_Linear | + HC_HTXnFLTs_Linear; + break; + default: + break; } vmesa->regHTXnMPMD_1 &= ~(HC_HTXnMPMD_SMASK | HC_HTXnMPMD_TMASK); |