softpipe: disable vertex texturing with draw/llvm
authorBrian Paul <brianp@vmware.com>
Fri, 5 Nov 2010 20:40:33 +0000 (14:40 -0600)
committerBrian Paul <brianp@vmware.com>
Fri, 5 Nov 2010 20:41:40 +0000 (14:41 -0600)
This is a temporary work around to prevent crashes with glean/glsl1
(for example) which try to do vertex shader texturing.

src/gallium/drivers/softpipe/sp_screen.c

index d90cf56808ccf1dd5d698a0d69739416d89d088d..5f171d314a3c5b7ea89e267df9a64f730f37d192 100644 (file)
@@ -64,7 +64,12 @@ softpipe_get_param(struct pipe_screen *screen, enum pipe_cap param)
    case PIPE_CAP_MAX_TEXTURE_IMAGE_UNITS:
       return PIPE_MAX_SAMPLERS;
    case PIPE_CAP_MAX_VERTEX_TEXTURE_UNITS:
+#ifdef HAVE_LLVM
+      /* Softpipe doesn't yet know how to tell draw/llvm about textures */
+      return 0;
+#else
       return PIPE_MAX_VERTEX_SAMPLERS;
+#endif
    case PIPE_CAP_MAX_COMBINED_SAMPLERS:
       return PIPE_MAX_SAMPLERS + PIPE_MAX_VERTEX_SAMPLERS;
    case PIPE_CAP_NPOT_TEXTURES: