st/mesa: add GL_DEPTH_COMPONENT32 fallback formats
authorMarek Olšák <maraeo@gmail.com>
Sat, 28 May 2011 12:51:16 +0000 (14:51 +0200)
committerMarek Olšák <maraeo@gmail.com>
Mon, 30 May 2011 08:49:27 +0000 (10:49 +0200)
This makes D32 work again on chipsets which can't do it.

Reviewed-by: Brian Paul <brianp@vmware.com>
src/mesa/state_tracker/st_format.c

index de30b4fc6101d158c326eb8c28c5fd01aaeba94e..4360ed7d65264d48e6817f1b05f30c3da912cc8f 100644 (file)
@@ -747,7 +747,10 @@ static struct format_mapping format_map[] = {
    },
    {
       { GL_DEPTH_COMPONENT32, 0 },
-      { PIPE_FORMAT_Z32_UNORM, 0 }
+      { PIPE_FORMAT_Z32_UNORM,
+        PIPE_FORMAT_Z24X8_UNORM, PIPE_FORMAT_X8Z24_UNORM,
+        PIPE_FORMAT_Z16_UNORM,
+        PIPE_FORMAT_Z24_UNORM_S8_USCALED, PIPE_FORMAT_S8_USCALED_Z24_UNORM, 0 }
    },
    {
       { GL_DEPTH_COMPONENT, 0 },