From 5bc35a823a7bdfd96d8a2428ed5630d04053ad34 Mon Sep 17 00:00:00 2001 From: Michal Krol Date: Wed, 15 Feb 2006 11:03:57 +0000 Subject: Enable texcoords when program object in use. --- src/mesa/main/texstate.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/main/texstate.c b/src/mesa/main/texstate.c index 46cebe91067..dce8c362da3 100644 --- a/src/mesa/main/texstate.c +++ b/src/mesa/main/texstate.c @@ -2937,8 +2937,11 @@ update_texture_state( GLcontext *ctx ) ctx->Texture._EnabledCoordUnits = ctx->Texture._EnabledUnits; /* Fragment programs may need texture coordinates but not the * corresponding texture images. - */ - if (ctx->FragmentProgram._Enabled) { + */ + if (ctx->ShaderObjects.CurrentProgram != NULL) { + ctx->Texture._EnabledCoordUnits |= (1 << 8) - 1; + } + else if (ctx->FragmentProgram._Enabled) { ctx->Texture._EnabledCoordUnits |= (ctx->FragmentProgram.Current->Base.InputsRead >> FRAG_ATTRIB_TEX0); } -- cgit v1.2.3