r300g: consolidate params
authorMarek Olšák <maraeo@gmail.com>
Mon, 21 Dec 2009 01:10:34 +0000 (02:10 +0100)
committerCorbin Simpson <MostAwesomeDude@gmail.com>
Wed, 6 Jan 2010 20:49:15 +0000 (12:49 -0800)
src/gallium/drivers/r300/r300_screen.c

index 2a8667d483556cdb1915da3c6fd35f78f56eb651..287664b1d20013060dad0ef9c2c87b52cb2bb683 100644 (file)
@@ -83,6 +83,7 @@ static int r300_get_param(struct pipe_screen* pscreen, int param)
 
     switch (param) {
         case PIPE_CAP_MAX_TEXTURE_IMAGE_UNITS:
+        case PIPE_CAP_MAX_COMBINED_SAMPLERS:
             /* XXX I'm told this goes up to 16 */
             return 8;
         case PIPE_CAP_NPOT_TEXTURES:
@@ -143,9 +144,11 @@ static int r300_get_param(struct pipe_screen* pscreen, int param)
         case PIPE_CAP_BLEND_EQUATION_SEPARATE:
             return 1;
         case PIPE_CAP_SM3:
-            return 1;
-        case PIPE_CAP_MAX_COMBINED_SAMPLERS:
-            return 8;
+            if (r300screen->caps->is_r500) {
+                return 1;
+            } else {
+                return 0;
+            }
         default:
             debug_printf("r300: Implementation error: Bad param %d\n",
                 param);