aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/main/texformat.c
diff options
context:
space:
mode:
authorJakob Bornecrantz <[email protected]>2008-06-06 16:12:55 +0200
committerJakob Bornecrantz <[email protected]>2008-06-08 16:58:19 +0200
commitf4535f6e5ae63d8c59428cf190a95e0eb4ae233d (patch)
treedbc9f979d2abeae6b694544904e00b0e7e739aad /src/mesa/main/texformat.c
parenta47c222803483c208f720e3fb5015050d4d0eaf4 (diff)
mesa: Add MESA_FORMAT_S8_Z24 texture format
None of the fetch and store functions implemented. This atleast stops shadowtex from locking the GPU on i915 with the linux-dri-x86 target. It most of it looks okay, with the exception of actually displaying the texture.
Diffstat (limited to 'src/mesa/main/texformat.c')
-rw-r--r--src/mesa/main/texformat.c35
1 files changed, 35 insertions, 0 deletions
diff --git a/src/mesa/main/texformat.c b/src/mesa/main/texformat.c
index 88fbd8f07c2..d479bf510ee 100644
--- a/src/mesa/main/texformat.c
+++ b/src/mesa/main/texformat.c
@@ -1207,6 +1207,41 @@ const struct gl_texture_format _mesa_texformat_z24_s8 = {
store_texel_z24_s8 /* StoreTexel */
};
+const struct gl_texture_format _mesa_texformat_s8_z24 = {
+ MESA_FORMAT_S8_Z24, /* MesaFormat */
+ GL_DEPTH_STENCIL_EXT, /* BaseFormat */
+ GL_UNSIGNED_NORMALIZED_ARB, /* DataType */
+ 0, /* RedBits */
+ 0, /* GreenBits */
+ 0, /* BlueBits */
+ 0, /* AlphaBits */
+ 0, /* LuminanceBits */
+ 0, /* IntensityBits */
+ 0, /* IndexBits */
+ 24, /* DepthBits */
+ 8, /* StencilBits */
+ 4, /* TexelBytes */
+#if 0
+ _mesa_texstore_s8_z24, /* StoreTexImageFunc */
+#else
+ _mesa_texstore_z24_s8, /* StoreTexImageFunc */
+#endif
+ NULL, /* FetchTexel1D */
+ NULL, /* FetchTexel2D */
+ NULL, /* FetchTexel3D */
+#if 0
+ fetch_texel_1d_f_s8_z24, /* FetchTexel1Df */
+ fetch_texel_2d_f_s8_z24, /* FetchTexel2Df */
+ fetch_texel_3d_f_s8_z24, /* FetchTexel3Df */
+ store_texel_s8_z24 /* StoreTexel */
+#else
+ fetch_texel_1d_f_z24_s8, /* FetchTexel1Df */
+ fetch_texel_2d_f_z24_s8, /* FetchTexel2Df */
+ fetch_texel_3d_f_z24_s8, /* FetchTexel3Df */
+ store_texel_z24_s8 /* StoreTexel */
+#endif
+};
+
const struct gl_texture_format _mesa_texformat_z16 = {
MESA_FORMAT_Z16, /* MesaFormat */
GL_DEPTH_COMPONENT, /* BaseFormat */