summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/i915/intel_pixel.c
diff options
context:
space:
mode:
authorBrian <brian.paul@tungstengraphics.com>2007-06-20 11:01:09 -0600
committerBrian <brian.paul@tungstengraphics.com>2007-06-20 11:01:09 -0600
commitf9c17ec58a492a7657ea120fa394056a680b9ec5 (patch)
tree69d9bb83477d3bd3e939611564c87c2439e46598 /src/mesa/drivers/dri/i915/intel_pixel.c
parentbd8eeb7ed09be698896d26c75aa60659efaa25a6 (diff)
parenta4af3e5ab3fa0f45c25673c93d802cdff087145c (diff)
Merge branch 'master' of git+ssh://brianp@git.freedesktop.org/git/mesa/mesa
Diffstat (limited to 'src/mesa/drivers/dri/i915/intel_pixel.c')
-rw-r--r--src/mesa/drivers/dri/i915/intel_pixel.c18
1 files changed, 15 insertions, 3 deletions
diff --git a/src/mesa/drivers/dri/i915/intel_pixel.c b/src/mesa/drivers/dri/i915/intel_pixel.c
index 535cbfcb26..a52a81bf13 100644
--- a/src/mesa/drivers/dri/i915/intel_pixel.c
+++ b/src/mesa/drivers/dri/i915/intel_pixel.c
@@ -440,9 +440,21 @@ intelDrawPixels( GLcontext *ctx,
fprintf(stderr, "%s\n", __FUNCTION__);
if (!intelTryDrawPixels( ctx, x, y, width, height, format, type,
- unpack, pixels ))
- _swrast_DrawPixels( ctx, x, y, width, height, format, type,
- unpack, pixels );
+ unpack, pixels )) {
+ if (ctx->FragmentProgram._Current ==
+ ctx->FragmentProgram._TexEnvProgram) {
+ /* don't want the i915 texenv program to be applied to DrawPixels */
+ struct gl_fragment_program *fpSave = ctx->FragmentProgram._Current;
+ ctx->FragmentProgram._Current = NULL;
+ _swrast_DrawPixels( ctx, x, y, width, height, format, type,
+ unpack, pixels );
+ ctx->FragmentProgram._Current = fpSave;
+ }
+ else {
+ _swrast_DrawPixels( ctx, x, y, width, height, format, type,
+ unpack, pixels );
+ }
+ }
}