swrast: restore !shader check around add_specular()
[mesa.git] / src / mesa / swrast / s_atifragshader.c
index 458fe18163eb2042480bb16cb4228999c53ba28d..5fefae6c42b38ce1cf3928acd3a68ce11b42c363 100644 (file)
@@ -47,17 +47,12 @@ static void
 fetch_texel(GLcontext * ctx, const GLfloat texcoord[4], GLfloat lambda,
            GLuint unit, GLfloat color[4])
 {
-   GLchan rgba[4];
    SWcontext *swrast = SWRAST_CONTEXT(ctx);
 
    /* XXX use a float-valued TextureSample routine here!!! */
    swrast->TextureSample[unit](ctx, ctx->Texture.Unit[unit]._Current,
                                1, (const GLfloat(*)[4]) texcoord,
-                               &lambda, &rgba);
-   color[0] = CHAN_TO_FLOAT(rgba[0]);
-   color[1] = CHAN_TO_FLOAT(rgba[1]);
-   color[2] = CHAN_TO_FLOAT(rgba[2]);
-   color[3] = CHAN_TO_FLOAT(rgba[3]);
+                               &lambda, (GLfloat (*)[4]) color);
 }
 
 static void