panfrost: Report MSAA 4x supported for dEQP
authorAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Sat, 4 Jan 2020 18:23:18 +0000 (13:23 -0500)
committerAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Mon, 6 Jan 2020 12:49:58 +0000 (07:49 -0500)
Fixes dEQP-GLES3.functional.state_query.integers.max_samples_getinteger64

We'll have to actually implement multisampling next, but hey.

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
src/gallium/drivers/panfrost/pan_screen.c

index 263dcd0fae93456fc6d612a88d637dd9a4211bd1..680bae1de1aa76ae0fc34f246361f52ac2e16b91 100644 (file)
@@ -427,7 +427,16 @@ panfrost_is_format_supported( struct pipe_screen *screen,
         if (!format_desc)
                 return false;
 
-        if (sample_count > 1)
+        /* MSAA 4x supported, but no more. Technically some revisions of the
+         * hardware can go up to 16x but we don't support higher modes yet. */
+
+        if (sample_count > 1 && !(pan_debug & PAN_DBG_DEQP))
+                return false;
+
+        if (sample_count > 4)
+                return false;
+
+        if (MAX2(sample_count, 1) != MAX2(storage_sample_count, 1))
                 return false;
 
         /* Format wishlist */