gallivm: Fix SoA cubemap derivative computation.
authorJosé Fonseca <jfonseca@vmware.com>
Sun, 17 Oct 2010 16:32:41 +0000 (09:32 -0700)
committerJosé Fonseca <jfonseca@vmware.com>
Sun, 17 Oct 2010 16:43:18 +0000 (09:43 -0700)
Derivatives are now scalar.

Broken since 17dbd41cf23e7e7de2f27e5e9252d7f792d932f3.

src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c

index 8c03284621c33fdad6b2e17e4a041b1959486d65..53cc0c5f34541c7c897a7e4509247ef1283fff72 100644 (file)
@@ -963,12 +963,12 @@ lp_build_sample_general(struct lp_build_sample_context *bld,
       r = lp_build_broadcast_scalar(&bld->int_coord_bld, face); /* vec */
 
       /* recompute ddx, ddy using the new (s,t) face texcoords */
-      face_ddx[0] = lp_build_ddx(&bld->coord_bld, s);
-      face_ddx[1] = lp_build_ddx(&bld->coord_bld, t);
+      face_ddx[0] = lp_build_scalar_ddx(&bld->coord_bld, s);
+      face_ddx[1] = lp_build_scalar_ddx(&bld->coord_bld, t);
       face_ddx[2] = NULL;
       face_ddx[3] = NULL;
-      face_ddy[0] = lp_build_ddy(&bld->coord_bld, s);
-      face_ddy[1] = lp_build_ddy(&bld->coord_bld, t);
+      face_ddy[0] = lp_build_scalar_ddy(&bld->coord_bld, s);
+      face_ddy[1] = lp_build_scalar_ddy(&bld->coord_bld, t);
       face_ddy[2] = NULL;
       face_ddy[3] = NULL;
       ddx = face_ddx;