summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2011-11-03 19:56:51 -0600
committerBrian Paul <[email protected]>2011-11-07 14:25:47 -0700
commitb64dc2a275714ae67c735298d8104ff292c60edf (patch)
treea5a573b6c1c9c6bf4fcaeec2721f9ef1ca70b06d
parentaf734468fee1e1fc0714557ddd199e2f91940afc (diff)
swrast: update program type assertion
Fixes bogus failed assertion when using NV_fragment_program, such as with demos/fplight.c Note: This is a candidate for the 7.11 branch.
-rw-r--r--src/mesa/swrast/s_context.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mesa/swrast/s_context.c b/src/mesa/swrast/s_context.c
index 9112cf30d81..98702f06817 100644
--- a/src/mesa/swrast/s_context.c
+++ b/src/mesa/swrast/s_context.c
@@ -249,7 +249,9 @@ _swrast_update_fog_state( struct gl_context *ctx )
SWcontext *swrast = SWRAST_CONTEXT(ctx);
const struct gl_fragment_program *fp = ctx->FragmentProgram._Current;
- assert((fp == NULL) || (fp->Base.Target == GL_FRAGMENT_PROGRAM_ARB));
+ assert((fp == NULL) ||
+ (fp->Base.Target == GL_FRAGMENT_PROGRAM_ARB) ||
+ (fp->Base.Target == GL_FRAGMENT_PROGRAM_NV));
/* determine if fog is needed, and if so, which fog mode */
swrast->_FogEnabled = (fp == NULL && ctx->Fog.Enabled);