diff options
author | Brian <brian@i915.localnet.net> | 2007-06-20 10:56:13 -0600 |
---|---|---|
committer | Brian <brian@i915.localnet.net> | 2007-06-20 10:56:13 -0600 |
commit | b9080dd5493eb23af6c5c494550c7b1cb481ca7b (patch) | |
tree | 2de49d7c038153738158edacf0882fe43eae2275 /src/mesa | |
parent | c1cb5412336be0e1067899318403ea573be9bb4d (diff) |
fix glDrawPixels + fragment program problem
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/swrast/s_span.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/mesa/swrast/s_span.c b/src/mesa/swrast/s_span.c index 90a3d5545f..3aaa3395e4 100644 --- a/src/mesa/swrast/s_span.c +++ b/src/mesa/swrast/s_span.c @@ -1169,10 +1169,17 @@ shade_texture_span(GLcontext *ctx, SWspan *span) if (ctx->FragmentProgram._Current || ctx->ATIFragmentShader._Enabled) { /* programmable shading */ + if (span->primitive == GL_BITMAP) { + if (span->array->ChanType != GL_FLOAT) + convert_color_type(span, GL_FLOAT, 0); + interpolate_active_attribs(ctx, span, ~FRAG_ATTRIB_COL0); + } + else { + /* point, line, triangle */ + interpolate_active_attribs(ctx, span, ~0); + } span->array->ChanType = GL_FLOAT; - interpolate_active_attribs(ctx, span, ~0); - if (!(span->arrayMask & SPAN_Z)) _swrast_span_interpolate_z (ctx, span); |