gallium: rename ZS stencil type to UINT (v2)
authorDave Airlie <airlied@redhat.com>
Sun, 11 Sep 2011 08:45:10 +0000 (09:45 +0100)
committerDave Airlie <airlied@redhat.com>
Tue, 11 Oct 2011 15:13:29 +0000 (16:13 +0100)
these are never USCALED, always UINT in reality.

taken from some work by Christoph Bumiller

v2: fixup formatting of table + tabs

Signed-off-by: Dave Airlie <airlied@redhat.com>
61 files changed:
src/gallium/auxiliary/postprocess/pp_init.c
src/gallium/auxiliary/util/u_format.c
src/gallium/auxiliary/util/u_format.csv
src/gallium/auxiliary/util/u_format.h
src/gallium/auxiliary/util/u_format_table.py
src/gallium/auxiliary/util/u_format_tests.c
src/gallium/auxiliary/util/u_format_zs.c
src/gallium/auxiliary/util/u_format_zs.h
src/gallium/auxiliary/util/u_pack_color.h
src/gallium/auxiliary/util/u_surface.c
src/gallium/auxiliary/util/u_tile.c
src/gallium/drivers/cell/ppu/cell_gen_fragment.c
src/gallium/drivers/cell/ppu/cell_screen.c
src/gallium/drivers/cell/spu/spu_command.c
src/gallium/drivers/cell/spu/spu_per_fragment_op.c
src/gallium/drivers/i915/i915_clear.c
src/gallium/drivers/i915/i915_screen.c
src/gallium/drivers/i915/i915_state_sampler.c
src/gallium/drivers/i915/i915_state_static.c
src/gallium/drivers/i915/i915_surface.c
src/gallium/drivers/i965/brw_misc_state.c
src/gallium/drivers/i965/brw_pipe_clear.c
src/gallium/drivers/i965/brw_resource_texture.c
src/gallium/drivers/i965/brw_screen.c
src/gallium/drivers/llvmpipe/lp_bld_depth.c
src/gallium/drivers/nv50/nv50_formats.c
src/gallium/drivers/nv50/nv50_miptree.c
src/gallium/drivers/nv50/nv50_surface.c
src/gallium/drivers/nvc0/nvc0_formats.c
src/gallium/drivers/nvc0/nvc0_miptree.c
src/gallium/drivers/nvc0/nvc0_surface.c
src/gallium/drivers/nvfx/nvfx_fragtex.c
src/gallium/drivers/nvfx/nvfx_screen.c
src/gallium/drivers/nvfx/nvfx_state_fb.c
src/gallium/drivers/r300/r300_blit.c
src/gallium/drivers/r300/r300_state_derived.c
src/gallium/drivers/r300/r300_texture.c
src/gallium/drivers/r600/evergreen_state.c
src/gallium/drivers/r600/r600_state.c
src/gallium/drivers/r600/r600_texture.c
src/gallium/drivers/softpipe/sp_quad_depth_test.c
src/gallium/drivers/svga/svga_format.c
src/gallium/drivers/svga/svga_pipe_clear.c
src/gallium/drivers/svga/svga_pipe_misc.c
src/gallium/drivers/svga/svga_state_framebuffer.c
src/gallium/include/pipe/p_format.h
src/gallium/state_trackers/d3d1x/d3d1xstutil/src/dxgi_enums.cpp
src/gallium/state_trackers/dri/common/dri_screen.c
src/gallium/state_trackers/egl/common/egl_g3d.c
src/gallium/state_trackers/glx/xlib/xm_api.c
src/gallium/state_trackers/vega/vg_context.c
src/gallium/state_trackers/wgl/stw_pixelformat.c
src/gallium/state_trackers/xa/xa_tracker.c
src/gallium/state_trackers/xorg/xorg_dri2.c
src/gallium/tests/unit/u_format_test.c
src/mesa/state_tracker/st_cb_drawpixels.c
src/mesa/state_tracker/st_cb_eglimage.c
src/mesa/state_tracker/st_cb_fbo.c
src/mesa/state_tracker/st_cb_readpixels.c
src/mesa/state_tracker/st_extensions.c
src/mesa/state_tracker/st_format.c

index fd9eb22dc0696451fa65d7b2d68bdda63ebd78df..d5d64e88ee676612cb4a4a245c5fc73c87431a88 100644 (file)
@@ -248,12 +248,12 @@ pp_init_fbos(struct pp_queue_t *ppq, const unsigned int w,
    if (!ppq->depth)
       goto error;
 
-   tmp_res.format = p->surf.format = PIPE_FORMAT_S8_USCALED_Z24_UNORM;
+   tmp_res.format = p->surf.format = PIPE_FORMAT_S8_UINT_Z24_UNORM;
 
    if (!p->screen->is_format_supported(p->screen, tmp_res.format,
                                        tmp_res.target, 1, tmp_res.bind)) {
 
-      tmp_res.format = p->surf.format = PIPE_FORMAT_Z24_UNORM_S8_USCALED;
+      tmp_res.format = p->surf.format = PIPE_FORMAT_Z24_UNORM_S8_UINT;
 
       if (!p->screen->is_format_supported(p->screen, tmp_res.format,
                                           tmp_res.target, 1, tmp_res.bind))
index 730dc31ac0354420880a16c13a5428caf5e7a0a8..e07462a75d0c71f699dbfcb0682c3a3cfdd64cf9 100644 (file)
@@ -561,8 +561,8 @@ util_format_translate(enum pipe_format dst_format,
          tmp_z = MALLOC(width * sizeof *tmp_z);
       }
 
-      if (src_format_desc->unpack_s_8uscaled &&
-          dst_format_desc->pack_s_8uscaled) {
+      if (src_format_desc->unpack_s_8uint &&
+          dst_format_desc->pack_s_8uint) {
          tmp_s = MALLOC(width * sizeof *tmp_s);
       }
 
@@ -573,8 +573,8 @@ util_format_translate(enum pipe_format dst_format,
          }
 
          if (tmp_s) {
-            src_format_desc->unpack_s_8uscaled(tmp_s, 0, src_row, src_stride, width, 1);
-            dst_format_desc->pack_s_8uscaled(dst_row, dst_stride, tmp_s, 0, width, 1);
+            src_format_desc->unpack_s_8uint(tmp_s, 0, src_row, src_stride, width, 1);
+            dst_format_desc->pack_s_8uint(dst_row, dst_stride, tmp_s, 0, width, 1);
          }
 
          dst_row += dst_step;
index 08aa0a49d2faf5d5bc47c5888f4f1255d89894bd..998ac416dc35fd42fb76185fe8f4e9b70a6b377f 100644 (file)
@@ -124,18 +124,18 @@ PIPE_FORMAT_R10SG10SB10SA2U_NORM  , plain, 1, 1, sn10, sn10, sn10, un2 , xyzw, r
 PIPE_FORMAT_R5SG5SB6U_NORM        , plain, 1, 1, sn5 , sn5 , un6 ,     , xyz1, rgb
 
 # Depth-stencil formats
-PIPE_FORMAT_S8_USCALED              , plain, 1, 1, u8  ,     ,     ,     , _x__, zs
+PIPE_FORMAT_S8_UINT                 , plain, 1, 1, up8 ,     ,     ,     , _x__, zs
 PIPE_FORMAT_Z16_UNORM               , plain, 1, 1, un16,     ,     ,     , x___, zs
 PIPE_FORMAT_Z32_UNORM               , plain, 1, 1, un32,     ,     ,     , x___, zs
 PIPE_FORMAT_Z32_FLOAT               , plain, 1, 1, f32 ,     ,     ,     , x___, zs
-PIPE_FORMAT_Z24_UNORM_S8_USCALED    , plain, 1, 1, un24, u8  ,     ,     , xy__, zs
-PIPE_FORMAT_S8_USCALED_Z24_UNORM    , plain, 1, 1, u8 ,  un24,     ,     , yx__, zs
-PIPE_FORMAT_X24S8_USCALED           , plain, 1, 1, x24,  u8  ,     ,     , _y__, zs
-PIPE_FORMAT_S8X24_USCALED           , plain, 1, 1, u8  , x24 ,     ,     , _x__, zs
+PIPE_FORMAT_Z24_UNORM_S8_UINT       , plain, 1, 1, un24, up8 ,     ,     , xy__, zs
+PIPE_FORMAT_S8_UINT_Z24_UNORM       , plain, 1, 1, up8 , un24,     ,     , yx__, zs
+PIPE_FORMAT_X24S8_UINT              , plain, 1, 1, x24 , up8 ,     ,     , _y__, zs
+PIPE_FORMAT_S8X24_UINT              , plain, 1, 1, up8 , x24 ,     ,     , _x__, zs
 PIPE_FORMAT_Z24X8_UNORM             , plain, 1, 1, un24, x8  ,     ,     , x___, zs
 PIPE_FORMAT_X8Z24_UNORM             , plain, 1, 1, x8  , un24,     ,     , y___, zs
-PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED , plain, 1, 1, f32,  u8  , x24 ,     , xy__, zs
-PIPE_FORMAT_X32_S8X24_USCALED       , plain, 1, 1, x32,  u8  , x24 ,     , _y__, zs
+PIPE_FORMAT_Z32_FLOAT_S8X24_UINT    , plain, 1, 1, f32 , up8 ,  x24,     , xy__, zs
+PIPE_FORMAT_X32_S8X24_UINT          , plain, 1, 1, x32 , up8 ,  x24,     , _y__, zs
 
 # YUV formats
 # http://www.fourcc.org/yuv.php#UYVY
@@ -338,4 +338,5 @@ PIPE_FORMAT_L32A32_UINT             , plain, 1, 1, up32, up32, , , xxxy, rgb
 PIPE_FORMAT_A32_SINT                , plain, 1, 1, sp32, , , , 000x, rgb
 PIPE_FORMAT_I32_SINT                , plain, 1, 1, sp32, , , , xxxx, rgb
 PIPE_FORMAT_L32_SINT                , plain, 1, 1, sp32, , , , xxx1, rgb
-PIPE_FORMAT_L32A32_SINT             , plain, 1, 1, sp32, sp32, , , xxxy, rgb
\ No newline at end of file
+PIPE_FORMAT_L32A32_SINT             , plain, 1, 1, sp32, sp32, , , xxxy, rgb
+
index 215a00ab551c317709b34ee5042f5a3256f6a173..99ee6767e83d06004e65c14e10fff9910d394ee7 100644 (file)
@@ -301,26 +301,26 @@ struct util_format_description
                    unsigned width, unsigned height);
 
    /**
-    * Unpack pixels to S8_USCALED.
+    * Unpack pixels to S8_UINT.
     * Note: strides are in bytes.
     *
     * Only defined for stencil formats.
     */
    void
-   (*unpack_s_8uscaled)(uint8_t *dst, unsigned dst_stride,
-                        const uint8_t *src, unsigned src_stride,
-                        unsigned width, unsigned height);
+   (*unpack_s_8uint)(uint8_t *dst, unsigned dst_stride,
+                     const uint8_t *src, unsigned src_stride,
+                     unsigned width, unsigned height);
 
    /**
-    * Pack pixels from S8_USCALED.
+    * Pack pixels from S8_UINT.
     * Note: strides are in bytes.
     *
     * Only defined for stencil formats.
     */
    void
-   (*pack_s_8uscaled)(uint8_t *dst, unsigned dst_stride,
-                      const uint8_t *src, unsigned src_stride,
-                      unsigned width, unsigned height);
+   (*pack_s_8uint)(uint8_t *dst, unsigned dst_stride,
+                   const uint8_t *src, unsigned src_stride,
+                   unsigned width, unsigned height);
 
   /**
     * Unpack pixel blocks to R32G32B32A32_UINT.
index 6c00b0df389374610d18f781bdc5776002e1a567..250a5359811fdb2ac9ad728a14a0d6912385271d 100755 (executable)
@@ -159,17 +159,17 @@ def write_format_table(formats):
             print "   NULL, /* unpack_z_float */" 
             print "   NULL, /* pack_z_float */" 
         if format.colorspace == ZS and format.swizzles[1] != SWIZZLE_NONE:
-            print "   &util_format_%s_unpack_s_8uscaled," % format.short_name() 
-            print "   &util_format_%s_pack_s_8uscaled," % format.short_name() 
+            print "   &util_format_%s_unpack_s_8uint," % format.short_name() 
+            print "   &util_format_%s_pack_s_8uint," % format.short_name() 
         else:
-            print "   NULL, /* unpack_s_8uscaled */" 
-            print "   NULL, /* pack_s_8uscaled */"
-        if format.channels[0].pure == True and format.channels[0].type == UNSIGNED:   
+            print "   NULL, /* unpack_s_8uint */" 
+            print "   NULL, /* pack_s_8uint */"
+        if format.colorspace != ZS and format.channels[0].pure == True and format.channels[0].type == UNSIGNED:
             print "   &util_format_%s_unpack_unsigned, /* unpack_rgba_uint */" % format.short_name() 
             print "   &util_format_%s_pack_unsigned, /* pack_rgba_uint */" % format.short_name()
             print "   &util_format_%s_unpack_signed, /* unpack_rgba_sint */" % format.short_name()
             print "   &util_format_%s_pack_signed  /* pack_rgba_sint */" % format.short_name()
-        elif format.channels[0].pure == True and format.channels[0].type == SIGNED:   
+        elif format.colorspace != ZS and format.channels[0].pure == True and format.channels[0].type == SIGNED:
             print "   &util_format_%s_unpack_unsigned, /* unpack_rgba_uint */" % format.short_name()
             print "   &util_format_%s_pack_unsigned, /* pack_rgba_uint */" % format.short_name()
             print "   &util_format_%s_unpack_signed, /* unpack_rgba_sint */" % format.short_name()
index b1df6c49c42c0a671c67c1ef2a1fcde85a577411..fc29d8d4817568f8fbc9061668d754669eefe724 100644 (file)
@@ -337,8 +337,8 @@ util_format_test_cases[] =
     * Depth-stencil formats
     */
 
-   {PIPE_FORMAT_S8_USCALED, PACKED_1x8(0xff), PACKED_1x8(0x00), UNPACKED_1x1(0.0,   0.0, 0.0, 0.0)},
-   {PIPE_FORMAT_S8_USCALED, PACKED_1x8(0xff), PACKED_1x8(0xff), UNPACKED_1x1(0.0, 255.0, 0.0, 0.0)},
+   {PIPE_FORMAT_S8_UINT, PACKED_1x8(0xff), PACKED_1x8(0x00), UNPACKED_1x1(0.0,   0.0, 0.0, 0.0)},
+   {PIPE_FORMAT_S8_UINT, PACKED_1x8(0xff), PACKED_1x8(0xff), UNPACKED_1x1(0.0, 255.0, 0.0, 0.0)},
 
    {PIPE_FORMAT_Z16_UNORM, PACKED_1x16(0xffff), PACKED_1x16(0x0000), UNPACKED_1x1(0.0, 0.0, 0.0, 0.0)},
    {PIPE_FORMAT_Z16_UNORM, PACKED_1x16(0xffff), PACKED_1x16(0xffff), UNPACKED_1x1(1.0, 0.0, 0.0, 0.0)},
@@ -349,15 +349,15 @@ util_format_test_cases[] =
    {PIPE_FORMAT_Z32_FLOAT, PACKED_1x32(0xffffffff), PACKED_1x32(0x00000000), UNPACKED_1x1(0.0, 0.0, 0.0, 0.0)},
    {PIPE_FORMAT_Z32_FLOAT, PACKED_1x32(0xffffffff), PACKED_1x32(0x3f800000), UNPACKED_1x1(1.0, 0.0, 0.0, 0.0)},
 
-   {PIPE_FORMAT_Z24_UNORM_S8_USCALED, PACKED_1x32(0xffffffff), PACKED_1x32(0x00000000), UNPACKED_1x1(0.0,   0.0, 0.0, 0.0)},
-   {PIPE_FORMAT_Z24_UNORM_S8_USCALED, PACKED_1x32(0xffffffff), PACKED_1x32(0x00ffffff), UNPACKED_1x1(1.0,   0.0, 0.0, 0.0)},
-   {PIPE_FORMAT_Z24_UNORM_S8_USCALED, PACKED_1x32(0xffffffff), PACKED_1x32(0xff000000), UNPACKED_1x1(0.0, 255.0, 0.0, 0.0)},
-   {PIPE_FORMAT_Z24_UNORM_S8_USCALED, PACKED_1x32(0xffffffff), PACKED_1x32(0xffffffff), UNPACKED_1x1(1.0, 255.0, 0.0, 0.0)},
+   {PIPE_FORMAT_Z24_UNORM_S8_UINT, PACKED_1x32(0xffffffff), PACKED_1x32(0x00000000), UNPACKED_1x1(0.0,   0.0, 0.0, 0.0)},
+   {PIPE_FORMAT_Z24_UNORM_S8_UINT, PACKED_1x32(0xffffffff), PACKED_1x32(0x00ffffff), UNPACKED_1x1(1.0,   0.0, 0.0, 0.0)},
+   {PIPE_FORMAT_Z24_UNORM_S8_UINT, PACKED_1x32(0xffffffff), PACKED_1x32(0xff000000), UNPACKED_1x1(0.0, 255.0, 0.0, 0.0)},
+   {PIPE_FORMAT_Z24_UNORM_S8_UINT, PACKED_1x32(0xffffffff), PACKED_1x32(0xffffffff), UNPACKED_1x1(1.0, 255.0, 0.0, 0.0)},
 
-   {PIPE_FORMAT_S8_USCALED_Z24_UNORM, PACKED_1x32(0xffffffff), PACKED_1x32(0x00000000), UNPACKED_1x1(0.0,   0.0, 0.0, 0.0)},
-   {PIPE_FORMAT_S8_USCALED_Z24_UNORM, PACKED_1x32(0xffffffff), PACKED_1x32(0xffffff00), UNPACKED_1x1(1.0,   0.0, 0.0, 0.0)},
-   {PIPE_FORMAT_S8_USCALED_Z24_UNORM, PACKED_1x32(0xffffffff), PACKED_1x32(0x000000ff), UNPACKED_1x1(0.0, 255.0, 0.0, 0.0)},
-   {PIPE_FORMAT_S8_USCALED_Z24_UNORM, PACKED_1x32(0xffffffff), PACKED_1x32(0xffffffff), UNPACKED_1x1(1.0, 255.0, 0.0, 0.0)},
+   {PIPE_FORMAT_S8_UINT_Z24_UNORM, PACKED_1x32(0xffffffff), PACKED_1x32(0x00000000), UNPACKED_1x1(0.0,   0.0, 0.0, 0.0)},
+   {PIPE_FORMAT_S8_UINT_Z24_UNORM, PACKED_1x32(0xffffffff), PACKED_1x32(0xffffff00), UNPACKED_1x1(1.0,   0.0, 0.0, 0.0)},
+   {PIPE_FORMAT_S8_UINT_Z24_UNORM, PACKED_1x32(0xffffffff), PACKED_1x32(0x000000ff), UNPACKED_1x1(0.0, 255.0, 0.0, 0.0)},
+   {PIPE_FORMAT_S8_UINT_Z24_UNORM, PACKED_1x32(0xffffffff), PACKED_1x32(0xffffffff), UNPACKED_1x1(1.0, 255.0, 0.0, 0.0)},
 
    {PIPE_FORMAT_Z24X8_UNORM, PACKED_1x32(0x00ffffff), PACKED_1x32(0x00000000), UNPACKED_1x1(0.0, 0.0, 0.0, 0.0)},
    {PIPE_FORMAT_Z24X8_UNORM, PACKED_1x32(0x00ffffff), PACKED_1x32(0x00ffffff), UNPACKED_1x1(1.0, 0.0, 0.0, 0.0)},
@@ -365,9 +365,9 @@ util_format_test_cases[] =
    {PIPE_FORMAT_X8Z24_UNORM, PACKED_1x32(0xffffff00), PACKED_1x32(0x00000000), UNPACKED_1x1(0.0, 0.0, 0.0, 0.0)},
    {PIPE_FORMAT_X8Z24_UNORM, PACKED_1x32(0xffffff00), PACKED_1x32(0xffffff00), UNPACKED_1x1(1.0, 0.0, 0.0, 0.0)},
 
-   {PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED, PACKED_2x32(0xffffffff, 0x000000ff), PACKED_2x32(0x00000000, 0x00000000), UNPACKED_1x1( 0.0,   0.0, 0.0, 0.0)},
-   {PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED, PACKED_2x32(0xffffffff, 0x000000ff), PACKED_2x32(0x3f800000, 0x00000000), UNPACKED_1x1( 1.0,   0.0, 0.0, 0.0)},
-   {PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED, PACKED_2x32(0xffffffff, 0x000000ff), PACKED_2x32(0x00000000, 0x000000ff), UNPACKED_1x1( 0.0, 255.0, 0.0, 0.0)},
+   {PIPE_FORMAT_Z32_FLOAT_S8X24_UINT, PACKED_2x32(0xffffffff, 0x000000ff), PACKED_2x32(0x00000000, 0x00000000), UNPACKED_1x1( 0.0,   0.0, 0.0, 0.0)},
+   {PIPE_FORMAT_Z32_FLOAT_S8X24_UINT, PACKED_2x32(0xffffffff, 0x000000ff), PACKED_2x32(0x3f800000, 0x00000000), UNPACKED_1x1( 1.0,   0.0, 0.0, 0.0)},
+   {PIPE_FORMAT_Z32_FLOAT_S8X24_UINT, PACKED_2x32(0xffffffff, 0x000000ff), PACKED_2x32(0x00000000, 0x000000ff), UNPACKED_1x1( 0.0, 255.0, 0.0, 0.0)},
 
    /*
     * YUV formats
index 80081e22f7c88e3d0eb08e83d59ce96d93395bff..816ef14204c54a3c35c3b15ff9a0d7b1b28c2edb 100644 (file)
@@ -112,7 +112,7 @@ z32_unorm_to_z32_float(uint32_t z)
 
 
 void
-util_format_s8_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride,
+util_format_s8_uint_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride,
                                          const uint8_t *src_row, unsigned src_stride,
                                          unsigned width, unsigned height)
 {
@@ -125,7 +125,7 @@ util_format_s8_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride,
 }
 
 void
-util_format_s8_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride,
+util_format_s8_uint_pack_s_8uint(uint8_t *dst_row, unsigned dst_stride,
                                        const uint8_t *src_row, unsigned src_stride,
                                        unsigned width, unsigned height)
 {
@@ -353,7 +353,7 @@ util_format_z32_float_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride,
 }
 
 void
-util_format_z24_unorm_s8_uscaled_unpack_z_float(float *dst_row, unsigned dst_stride,
+util_format_z24_unorm_s8_uint_unpack_z_float(float *dst_row, unsigned dst_stride,
                                                 const uint8_t *src_row, unsigned src_stride,
                                                 unsigned width, unsigned height)
 {
@@ -374,7 +374,7 @@ util_format_z24_unorm_s8_uscaled_unpack_z_float(float *dst_row, unsigned dst_str
 }
 
 void
-util_format_z24_unorm_s8_uscaled_pack_z_float(uint8_t *dst_row, unsigned dst_stride,
+util_format_z24_unorm_s8_uint_pack_z_float(uint8_t *dst_row, unsigned dst_stride,
                                               const float *src_row, unsigned src_stride,
                                               unsigned width, unsigned height)
 {
@@ -400,7 +400,7 @@ util_format_z24_unorm_s8_uscaled_pack_z_float(uint8_t *dst_row, unsigned dst_str
 }
 
 void
-util_format_z24_unorm_s8_uscaled_unpack_z_32unorm(uint32_t *dst_row, unsigned dst_stride,
+util_format_z24_unorm_s8_uint_unpack_z_32unorm(uint32_t *dst_row, unsigned dst_stride,
                                                   const uint8_t *src_row, unsigned src_stride,
                                                   unsigned width, unsigned height)
 {
@@ -421,7 +421,7 @@ util_format_z24_unorm_s8_uscaled_unpack_z_32unorm(uint32_t *dst_row, unsigned ds
 }
 
 void
-util_format_z24_unorm_s8_uscaled_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride,
+util_format_z24_unorm_s8_uint_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride,
                                                 const uint32_t *src_row, unsigned src_stride,
                                                 unsigned width, unsigned height)
 {
@@ -447,7 +447,7 @@ util_format_z24_unorm_s8_uscaled_pack_z_32unorm(uint8_t *dst_row, unsigned dst_s
 }
 
 void
-util_format_z24_unorm_s8_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride,
+util_format_z24_unorm_s8_uint_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride,
                                                    const uint8_t *src_row, unsigned src_stride,
                                                    unsigned width, unsigned height)
 {
@@ -468,7 +468,7 @@ util_format_z24_unorm_s8_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned ds
 }
 
 void
-util_format_z24_unorm_s8_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride,
+util_format_z24_unorm_s8_uint_pack_s_8uint(uint8_t *dst_row, unsigned dst_stride,
                                                  const uint8_t *src_row, unsigned src_stride,
                                                  unsigned width, unsigned height)
 {
@@ -494,7 +494,7 @@ util_format_z24_unorm_s8_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_
 }
 
 void
-util_format_s8_uscaled_z24_unorm_unpack_z_float(float *dst_row, unsigned dst_stride,
+util_format_s8_uint_z24_unorm_unpack_z_float(float *dst_row, unsigned dst_stride,
                                                 const uint8_t *src_row, unsigned src_stride,
                                                 unsigned width, unsigned height)
 {
@@ -515,7 +515,7 @@ util_format_s8_uscaled_z24_unorm_unpack_z_float(float *dst_row, unsigned dst_str
 }
 
 void
-util_format_s8_uscaled_z24_unorm_pack_z_float(uint8_t *dst_row, unsigned dst_stride,
+util_format_s8_uint_z24_unorm_pack_z_float(uint8_t *dst_row, unsigned dst_stride,
                                               const float *src_row, unsigned src_stride,
                                               unsigned width, unsigned height)
 {
@@ -541,7 +541,7 @@ util_format_s8_uscaled_z24_unorm_pack_z_float(uint8_t *dst_row, unsigned dst_str
 }
 
 void
-util_format_s8_uscaled_z24_unorm_unpack_z_32unorm(uint32_t *dst_row, unsigned dst_stride,
+util_format_s8_uint_z24_unorm_unpack_z_32unorm(uint32_t *dst_row, unsigned dst_stride,
                                                   const uint8_t *src_row, unsigned src_stride,
                                                   unsigned width, unsigned height)
 {
@@ -562,7 +562,7 @@ util_format_s8_uscaled_z24_unorm_unpack_z_32unorm(uint32_t *dst_row, unsigned ds
 }
 
 void
-util_format_s8_uscaled_z24_unorm_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride,
+util_format_s8_uint_z24_unorm_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride,
                                                 const uint32_t *src_row, unsigned src_stride,
                                                 unsigned width, unsigned height)
 {
@@ -588,7 +588,7 @@ util_format_s8_uscaled_z24_unorm_pack_z_32unorm(uint8_t *dst_row, unsigned dst_s
 }
 
 void
-util_format_s8_uscaled_z24_unorm_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride,
+util_format_s8_uint_z24_unorm_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride,
                                                    const uint8_t *src_row, unsigned src_stride,
                                                    unsigned width, unsigned height)
 {
@@ -609,7 +609,7 @@ util_format_s8_uscaled_z24_unorm_unpack_s_8uscaled(uint8_t *dst_row, unsigned ds
 }
 
 void
-util_format_s8_uscaled_z24_unorm_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride,
+util_format_s8_uint_z24_unorm_pack_s_8uint(uint8_t *dst_row, unsigned dst_stride,
                                                  const uint8_t *src_row, unsigned src_stride,
                                                  unsigned width, unsigned height)
 {
@@ -807,7 +807,7 @@ util_format_x8z24_unorm_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride,
 }
 
 void
-util_format_z32_float_s8x24_uscaled_unpack_z_float(float *dst_row, unsigned dst_stride,
+util_format_z32_float_s8x24_uint_unpack_z_float(float *dst_row, unsigned dst_stride,
                                                    const uint8_t *src_row, unsigned src_stride,
                                                    unsigned width, unsigned height)
 {
@@ -826,7 +826,7 @@ util_format_z32_float_s8x24_uscaled_unpack_z_float(float *dst_row, unsigned dst_
 }
 
 void
-util_format_z32_float_s8x24_uscaled_pack_z_float(uint8_t *dst_row, unsigned dst_stride,
+util_format_z32_float_s8x24_uint_pack_z_float(uint8_t *dst_row, unsigned dst_stride,
                                                  const float *src_row, unsigned src_stride,
                                                  unsigned width, unsigned height)
 {
@@ -845,7 +845,7 @@ util_format_z32_float_s8x24_uscaled_pack_z_float(uint8_t *dst_row, unsigned dst_
 }
 
 void
-util_format_z32_float_s8x24_uscaled_unpack_z_32unorm(uint32_t *dst_row, unsigned dst_stride,
+util_format_z32_float_s8x24_uint_unpack_z_32unorm(uint32_t *dst_row, unsigned dst_stride,
                                                      const uint8_t *src_row, unsigned src_stride,
                                                      unsigned width, unsigned height)
 {
@@ -864,7 +864,7 @@ util_format_z32_float_s8x24_uscaled_unpack_z_32unorm(uint32_t *dst_row, unsigned
 }
 
 void
-util_format_z32_float_s8x24_uscaled_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride,
+util_format_z32_float_s8x24_uint_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride,
                                                    const uint32_t *src_row, unsigned src_stride,
                                                    unsigned width, unsigned height)
 {
@@ -881,7 +881,7 @@ util_format_z32_float_s8x24_uscaled_pack_z_32unorm(uint8_t *dst_row, unsigned ds
 }
 
 void
-util_format_z32_float_s8x24_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride,
+util_format_z32_float_s8x24_uint_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride,
                                                       const uint8_t *src_row, unsigned src_stride,
                                                       unsigned width, unsigned height)
 {
@@ -900,7 +900,7 @@ util_format_z32_float_s8x24_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned
 }
 
 void
-util_format_z32_float_s8x24_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride,
+util_format_z32_float_s8x24_uint_pack_s_8uint(uint8_t *dst_row, unsigned dst_stride,
                                                     const uint8_t *src_row, unsigned src_stride,
                                                     unsigned width, unsigned height)
 {
@@ -920,54 +920,54 @@ util_format_z32_float_s8x24_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned d
 
 
 void
-util_format_x24s8_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height)
+util_format_x24s8_uint_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height)
 {
-   util_format_z24_unorm_s8_uscaled_unpack_s_8uscaled(dst_row, dst_stride,
+   util_format_z24_unorm_s8_uint_unpack_s_8uint(dst_row, dst_stride,
                                                      src_row, src_stride,
                                                      width, height);
 }
 
 void
-util_format_x24s8_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height)
+util_format_x24s8_uint_pack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height)
 {
-   util_format_z24_unorm_s8_uscaled_pack_s_8uscaled(dst_row, dst_stride,
+   util_format_z24_unorm_s8_uint_pack_s_8uint(dst_row, dst_stride,
                                                    src_row, src_stride,
                                                    width, height);
 }
 
 void
-util_format_s8x24_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height)
+util_format_s8x24_uint_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height)
 {
-   util_format_s8_uscaled_z24_unorm_unpack_s_8uscaled(dst_row, dst_stride,
+   util_format_s8_uint_z24_unorm_unpack_s_8uint(dst_row, dst_stride,
                                                      src_row, src_stride,
                                                      width, height);
 }
 
 void
-util_format_s8x24_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height)
+util_format_s8x24_uint_pack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height)
 {
-   util_format_s8_uscaled_z24_unorm_pack_s_8uscaled(dst_row, dst_stride,
+   util_format_s8_uint_z24_unorm_pack_s_8uint(dst_row, dst_stride,
                                                      src_row, src_stride,
                                                      width, height);
 }
 
 void
-util_format_x32_s8x24_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride,
+util_format_x32_s8x24_uint_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride,
                                                const uint8_t *src_row, unsigned src_stride,
                                                unsigned width, unsigned height)
 {
-   util_format_z32_float_s8x24_uscaled_unpack_s_8uscaled(dst_row, dst_stride,
+   util_format_z32_float_s8x24_uint_unpack_s_8uint(dst_row, dst_stride,
                                                         src_row, src_stride,
                                                         width, height);
 
 }
 
 void
-util_format_x32_s8x24_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride,
+util_format_x32_s8x24_uint_pack_s_8uint(uint8_t *dst_row, unsigned dst_stride,
                                              const uint8_t *src_row, unsigned src_stride,
                                              unsigned width, unsigned height)
 {
-   util_format_z32_float_s8x24_uscaled_pack_s_8uscaled(dst_row, dst_stride,
+   util_format_z32_float_s8x24_uint_pack_s_8uint(dst_row, dst_stride,
                                                        src_row, src_stride,
                                                       width, height);
 }
index 1604cc3eee2b04cfb443f21933e64629c72a5fa2..adddfaf3a74da7c4911979e0658f84c615a5519d 100644 (file)
 
 
 void
-util_format_s8_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_s8_uint_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_s8_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_s8_uint_pack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
@@ -90,51 +90,51 @@ util_format_z32_float_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride, cons
 
 
 void
-util_format_z24_unorm_s8_uscaled_unpack_z_float(float *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_z24_unorm_s8_uint_unpack_z_float(float *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_z24_unorm_s8_uscaled_pack_z_float(uint8_t *dst_row, unsigned dst_stride, const float *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_z24_unorm_s8_uint_pack_z_float(uint8_t *dst_row, unsigned dst_stride, const float *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_z24_unorm_s8_uscaled_unpack_z_32unorm(uint32_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_z24_unorm_s8_uint_unpack_z_32unorm(uint32_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_z24_unorm_s8_uscaled_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride, const uint32_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_z24_unorm_s8_uint_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride, const uint32_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_z24_unorm_s8_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_z24_unorm_s8_uint_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_z24_unorm_s8_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_z24_unorm_s8_uint_pack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_s8_uscaled_z24_unorm_unpack_z_float(float *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_s8_uint_z24_unorm_unpack_z_float(float *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_s8_uscaled_z24_unorm_pack_z_float(uint8_t *dst_row, unsigned dst_stride, const float *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_s8_uint_z24_unorm_pack_z_float(uint8_t *dst_row, unsigned dst_stride, const float *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_s8_uscaled_z24_unorm_unpack_z_32unorm(uint32_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_s8_uint_z24_unorm_unpack_z_32unorm(uint32_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_s8_uscaled_z24_unorm_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride, const uint32_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_s8_uint_z24_unorm_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride, const uint32_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_s8_uscaled_z24_unorm_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_s8_uint_z24_unorm_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_s8_uscaled_z24_unorm_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_s8_uint_z24_unorm_pack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
@@ -170,43 +170,43 @@ util_format_x8z24_unorm_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride, co
 
 
 void
-util_format_z32_float_s8x24_uscaled_unpack_z_float(float *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_z32_float_s8x24_uint_unpack_z_float(float *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_z32_float_s8x24_uscaled_pack_z_float(uint8_t *dst_row, unsigned dst_stride, const float *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_z32_float_s8x24_uint_pack_z_float(uint8_t *dst_row, unsigned dst_stride, const float *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_z32_float_s8x24_uscaled_unpack_z_32unorm(uint32_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_z32_float_s8x24_uint_unpack_z_32unorm(uint32_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_z32_float_s8x24_uscaled_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride, const uint32_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_z32_float_s8x24_uint_pack_z_32unorm(uint8_t *dst_row, unsigned dst_stride, const uint32_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_z32_float_s8x24_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_z32_float_s8x24_uint_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 
 void
-util_format_z32_float_s8x24_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_z32_float_s8x24_uint_pack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 void
-util_format_x24s8_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_x24s8_uint_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 void
-util_format_x24s8_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_x24s8_uint_pack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 void
-util_format_s8x24_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_s8x24_uint_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 void
-util_format_s8x24_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_s8x24_uint_pack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 void
-util_format_x32_s8x24_uscaled_unpack_s_8uscaled(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_x32_s8x24_uint_unpack_s_8uint(uint8_t *dst_row, unsigned dst_stride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 
 void
-util_format_x32_s8x24_uscaled_pack_s_8uscaled(uint8_t *dst_row, unsigned dst_sride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
+util_format_x32_s8x24_uint_pack_s_8uint(uint8_t *dst_row, unsigned dst_sride, const uint8_t *src_row, unsigned src_stride, unsigned width, unsigned height);
 #endif /* U_FORMAT_ZS_H_ */
index 9391f1b80e0c1899bc17107af6134dc1353e70e5..0bbf769a4e23aa48ec331e2364e73aa837eec943 100644 (file)
@@ -443,13 +443,13 @@ util_pack_mask_z(enum pipe_format format, uint32_t z)
    case PIPE_FORMAT_Z32_UNORM:
    case PIPE_FORMAT_Z32_FLOAT:
       return z;
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
    case PIPE_FORMAT_Z24X8_UNORM:
       return z & 0xffffff;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
    case PIPE_FORMAT_X8Z24_UNORM:
       return (z & 0xffffff) << 8;
-   case PIPE_FORMAT_S8_USCALED:
+   case PIPE_FORMAT_S8_UINT:
       return 0;
    default:
       debug_print_format("gallium: unhandled format in util_pack_mask_z()", format);
@@ -463,7 +463,7 @@ static INLINE uint64_t
 util_pack64_mask_z(enum pipe_format format, uint32_t z)
 {
    switch (format) {
-   case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+   case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
       return z;
    default:
       return util_pack_mask_z(format, z);
@@ -477,13 +477,13 @@ util_pack_mask_z_stencil(enum pipe_format format, uint32_t z, uint8_t s)
    uint32_t packed = util_pack_mask_z(format, z);
 
    switch (format) {
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       packed |= (uint32_t)s << 24;
       break;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
       packed |= s;
       break;
-   case PIPE_FORMAT_S8_USCALED:
+   case PIPE_FORMAT_S8_UINT:
       packed |= s;
       break;
    default:
@@ -500,7 +500,7 @@ util_pack64_mask_z_stencil(enum pipe_format format, uint32_t z, uint8_t s)
    uint64_t packed;
 
    switch (format) {
-   case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+   case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
       packed = util_pack64_mask_z(format, z);
       packed |= (uint64_t)s << 32ull;
       return packed;
@@ -534,17 +534,17 @@ util_pack_z(enum pipe_format format, double z)
    case PIPE_FORMAT_Z32_FLOAT:
       fui.f = (float)z;
       return fui.ui;
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
    case PIPE_FORMAT_Z24X8_UNORM:
       if (z == 1.0)
          return 0xffffff;
       return (uint32_t) (z * 0xffffff);
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
    case PIPE_FORMAT_X8Z24_UNORM:
       if (z == 1.0)
          return 0xffffff00;
       return ((uint32_t) (z * 0xffffff)) << 8;
-   case PIPE_FORMAT_S8_USCALED:
+   case PIPE_FORMAT_S8_UINT:
       /* this case can get it via util_pack_z_stencil() */
       return 0;
    default:
@@ -564,7 +564,7 @@ util_pack64_z(enum pipe_format format, double z)
       return 0;
 
    switch (format) {
-   case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+   case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
       fui.f = (float)z;
       return fui.ui;
    default:
@@ -583,13 +583,13 @@ util_pack_z_stencil(enum pipe_format format, double z, uint8_t s)
    uint32_t packed = util_pack_z(format, z);
 
    switch (format) {
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       packed |= (uint32_t)s << 24;
       break;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
       packed |= s;
       break;
-   case PIPE_FORMAT_S8_USCALED:
+   case PIPE_FORMAT_S8_UINT:
       packed |= s;
       break;
    default:
@@ -606,7 +606,7 @@ util_pack64_z_stencil(enum pipe_format format, double z, uint8_t s)
    uint64_t packed;
 
    switch (format) {
-   case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+   case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
       packed = util_pack64_z(format, z);
       packed |= (uint64_t)s << 32ull;
       break;
index 308511b33c4ca5583015479f92ea126ae0460fa8..c7fbd3657f960c8abc42c84326ae7f449569db40 100644 (file)
@@ -311,7 +311,7 @@ util_clear_depth_stencil(struct pipe_context *pipe,
 
       switch (util_format_get_blocksize(dst->format)) {
       case 1:
-         assert(dst->format == PIPE_FORMAT_S8_USCALED);
+         assert(dst->format == PIPE_FORMAT_S8_UINT);
          if(dst_stride == width)
             memset(dst_map, (ubyte) zstencil, height * width);
          else {
@@ -341,10 +341,10 @@ util_clear_depth_stencil(struct pipe_context *pipe,
          }
          else {
             uint32_t dst_mask;
-            if (dst->format == PIPE_FORMAT_Z24_UNORM_S8_USCALED)
+            if (dst->format == PIPE_FORMAT_Z24_UNORM_S8_UINT)
                dst_mask = 0xffffff00;
             else {
-               assert(dst->format == PIPE_FORMAT_S8_USCALED_Z24_UNORM);
+               assert(dst->format == PIPE_FORMAT_S8_UINT_Z24_UNORM);
                dst_mask = 0xffffff;
             }
             if (clear_flags & PIPE_CLEAR_DEPTH)
@@ -364,7 +364,7 @@ util_clear_depth_stencil(struct pipe_context *pipe,
          uint64_t zstencil = util_pack64_z_stencil(dst->texture->format,
                                                    depth, stencil);
 
-         assert(dst->format == PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED);
+         assert(dst->format == PIPE_FORMAT_Z32_FLOAT_S8X24_UINT);
 
          if (!need_rmw) {
             for (i = 0; i < height; i++) {
index 6342bfbfc3a333413aeb6cbf8e19dec0c74cb3c4..02bdb731d386c1b7577857a7fa60a476170a0e73 100644 (file)
@@ -164,7 +164,7 @@ z32_get_tile_rgba(const unsigned *src,
 }
 
 
-/*** PIPE_FORMAT_Z24_UNORM_S8_USCALED ***/
+/*** PIPE_FORMAT_Z24_UNORM_S8_UINT ***/
 
 /**
  * Return Z component as four float in [0,1].  Stencil part ignored.
@@ -191,7 +191,7 @@ s8z24_get_tile_rgba(const unsigned *src,
 }
 
 
-/*** PIPE_FORMAT_S8_USCALED_Z24_UNORM ***/
+/*** PIPE_FORMAT_S8_UINT_Z24_UNORM ***/
 
 /**
  * Return Z component as four float in [0,1].  Stencil part ignored.
@@ -217,7 +217,7 @@ z24s8_get_tile_rgba(const unsigned *src,
    }
 }
 
-/*** PIPE_FORMAT_S8X24_USCALED ***/
+/*** PIPE_FORMAT_S8X24_UINT ***/
 
 /**
  * Return S component as four uint32_t in [0..255].  Z part ignored.
@@ -244,7 +244,7 @@ s8x24_get_tile_rgba(const unsigned *src,
    }
 }
 
-/*** PIPE_FORMAT_X24S8_USCALED ***/
+/*** PIPE_FORMAT_X24S8_UINT ***/
 
 /**
  * Return S component as four uint32_t in [0..255].  Z part ignored.
@@ -318,7 +318,7 @@ z32f_get_tile_rgba(const float *src,
    }
 }
 
-/*** PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED ***/
+/*** PIPE_FORMAT_Z32_FLOAT_S8X24_UINT ***/
 
 /**
  * Return each Z value as four floats in [0,1].
@@ -358,27 +358,27 @@ pipe_tile_raw_to_rgba(enum pipe_format format,
    case PIPE_FORMAT_Z32_UNORM:
       z32_get_tile_rgba((unsigned *) src, w, h, dst, dst_stride);
       break;
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
    case PIPE_FORMAT_Z24X8_UNORM:
       s8z24_get_tile_rgba((unsigned *) src, w, h, dst, dst_stride);
       break;
-   case PIPE_FORMAT_S8_USCALED:
+   case PIPE_FORMAT_S8_UINT:
       s8_get_tile_rgba((unsigned char *) src, w, h, dst, dst_stride);
       break;
-   case PIPE_FORMAT_X24S8_USCALED:
+   case PIPE_FORMAT_X24S8_UINT:
       s8x24_get_tile_rgba((unsigned *) src, w, h, dst, dst_stride);
       break;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
    case PIPE_FORMAT_X8Z24_UNORM:
       z24s8_get_tile_rgba((unsigned *) src, w, h, dst, dst_stride);
       break;
-   case PIPE_FORMAT_S8X24_USCALED:
+   case PIPE_FORMAT_S8X24_UINT:
       x24s8_get_tile_rgba((unsigned *) src, w, h, dst, dst_stride);
       break;
    case PIPE_FORMAT_Z32_FLOAT:
       z32f_get_tile_rgba((float *) src, w, h, dst, dst_stride);
       break;
-   case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+   case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
       z32f_x24s8_get_tile_rgba((float *) src, w, h, dst, dst_stride);
       break;
    default:
@@ -489,18 +489,18 @@ pipe_put_tile_rgba_format(struct pipe_context *pipe,
    case PIPE_FORMAT_Z32_UNORM:
       /*z32_put_tile_rgba((unsigned *) packed, w, h, p, src_stride);*/
       break;
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
    case PIPE_FORMAT_Z24X8_UNORM:
       /*s8z24_put_tile_rgba((unsigned *) packed, w, h, p, src_stride);*/
       break;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
    case PIPE_FORMAT_X8Z24_UNORM:
       /*z24s8_put_tile_rgba((unsigned *) packed, w, h, p, src_stride);*/
       break;
    case PIPE_FORMAT_Z32_FLOAT:
       /*z32f_put_tile_rgba((unsigned *) packed, w, h, p, src_stride);*/
       break;
-   case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+   case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
       /*z32f_s8x24_put_tile_rgba((unsigned *) packed, w, h, p, src_stride);*/
       break;
    default:
@@ -607,7 +607,7 @@ pipe_get_tile_z(struct pipe_context *pipe,
          }
       }
       break;
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
    case PIPE_FORMAT_Z24X8_UNORM:
       {
          const uint *ptrc
@@ -622,7 +622,7 @@ pipe_get_tile_z(struct pipe_context *pipe,
          }
       }
       break;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
    case PIPE_FORMAT_X8Z24_UNORM:
       {
          const uint *ptrc
@@ -691,7 +691,7 @@ pipe_put_tile_z(struct pipe_context *pipe,
          }
       }
       break;
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       {
          uint *pDest = (uint *) (map + y * pt->stride + x*4);
          /*assert((pt->usage & PIPE_TRANSFER_READ_WRITE) == PIPE_TRANSFER_READ_WRITE);*/
@@ -718,7 +718,7 @@ pipe_put_tile_z(struct pipe_context *pipe,
          }
       }
       break;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
       {
          uint *pDest = (uint *) (map + y * pt->stride + x*4);
          /*assert((pt->usage & PIPE_TRANSFER_READ_WRITE) == PIPE_TRANSFER_READ_WRITE);*/
index 628bc1c694b44f98576256f6a2533a0d10ccd049..76a851780074205020364dfabcee255a97db85fc 100644 (file)
@@ -1859,7 +1859,7 @@ gen_depth_stencil(struct cell_context *cell,
    spe_comment(f, 0, "Fetch Z/stencil quad from tile");
 
    switch(zs_format) {
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED: /* fall through */
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT: /* fall through */
    case PIPE_FORMAT_Z24X8_UNORM:
       /* prepare mask to extract Z vals from ZS vals */
       spe_load_uint(f, zmask_reg, 0x00ffffff);
@@ -1880,7 +1880,7 @@ gen_depth_stencil(struct cell_context *cell,
       spe_rotmi(f, fbS_reg, fbZS_reg, -24);
       break;
 
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM: /* fall through */
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM: /* fall through */
    case PIPE_FORMAT_X8Z24_UNORM:
       /* convert fragment Z from [0,1] to 32-bit ints */
       spe_cfltu(f, fragZ_reg, fragZ_reg, 32);
@@ -1969,12 +1969,12 @@ gen_depth_stencil(struct cell_context *cell,
        * fbS_reg has four 8-bit Z values in bits [7..0].
        */
       spe_comment(f, 0, "Store quad's depth/stencil values in tile");
-      if (zs_format == PIPE_FORMAT_Z24_UNORM_S8_USCALED ||
+      if (zs_format == PIPE_FORMAT_Z24_UNORM_S8_UINT ||
           zs_format == PIPE_FORMAT_Z24X8_UNORM) {
          spe_shli(f, fbS_reg, fbS_reg, 24); /* fbS = fbS << 24 */
          spe_or(f, fbZS_reg, fbS_reg, fbZ_reg); /* fbZS = fbS | fbZ */
       }
-      else if (zs_format == PIPE_FORMAT_S8_USCALED_Z24_UNORM ||
+      else if (zs_format == PIPE_FORMAT_S8_UINT_Z24_UNORM ||
                zs_format == PIPE_FORMAT_X8Z24_UNORM) {
          spe_shli(f, fbZ_reg, fbZ_reg, 8); /* fbZ = fbZ << 8 */
          spe_or(f, fbZS_reg, fbS_reg, fbZ_reg); /* fbZS = fbS | fbZ */
@@ -1985,7 +1985,7 @@ gen_depth_stencil(struct cell_context *cell,
       else if (zs_format == PIPE_FORMAT_Z16_UNORM) {
          spe_move(f, fbZS_reg, fbZ_reg); /* fbZS = fbZ */
       }
-      else if (zs_format == PIPE_FORMAT_S8_USCALED) {
+      else if (zs_format == PIPE_FORMAT_S8_UINT) {
          ASSERT(0);   /* XXX to do */
       }
       else {
@@ -2015,7 +2015,7 @@ gen_depth_stencil(struct cell_context *cell,
  * code before the fragment shader to cull fragments/quads that are
  * totally occluded/discarded.
  *
- * XXX we only support PIPE_FORMAT_S8_USCALED_Z24_UNORM z/stencil buffer right now.
+ * XXX we only support PIPE_FORMAT_S8_UINT_Z24_UNORM z/stencil buffer right now.
  *
  * See the spu_default_fragment_ops() function to see how the per-fragment
  * operations would be done with ordinary C code.
index 14a6173ff350f05a4089b5e6376a8f54373fa41b..86acbc73f8adc13861a370d827df8957bd8600fd 100644 (file)
@@ -166,7 +166,7 @@ cell_is_format_supported( struct pipe_screen *screen,
 
    /* only a few formats are known to work at this time */
    switch (format) {
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
    case PIPE_FORMAT_Z24X8_UNORM:
    case PIPE_FORMAT_B8G8R8A8_UNORM:
    case PIPE_FORMAT_I8_UNORM:
index f16cabc027094d62e704091095d78d759d74a8e6..6f8ba9562d296ad1604e5979909827b0779e3fb2 100644 (file)
@@ -337,8 +337,8 @@ cmd_state_framebuffer(const struct cell_command_framebuffer *cmd)
       spu.fb.zsize = 4;
       spu.fb.zscale = (float) 0xffffffffu;
       break;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
    case PIPE_FORMAT_X8Z24_UNORM:
    case PIPE_FORMAT_Z24X8_UNORM:
       spu.fb.zsize = 4;
index 3b9566042a1d1369f19c6f819b6dedecd7666251..2415226a2443748f485c59d65d100f14c5d7400c 100644 (file)
@@ -138,13 +138,13 @@ spu_fallback_fragment_ops(uint x, uint y,
 
       if (spu.depth_stencil_alpha.stencil[0].enabled) {
          /* do stencil test */
-         ASSERT(spu.fb.depth_format == PIPE_FORMAT_Z24_UNORM_S8_USCALED);
+         ASSERT(spu.fb.depth_format == PIPE_FORMAT_Z24_UNORM_S8_UINT);
 
       }
       else if (spu.depth_stencil_alpha.depth.enabled) {
          /* do depth test */
 
-         ASSERT(spu.fb.depth_format == PIPE_FORMAT_Z24_UNORM_S8_USCALED ||
+         ASSERT(spu.fb.depth_format == PIPE_FORMAT_Z24_UNORM_S8_UINT ||
                 spu.fb.depth_format == PIPE_FORMAT_Z24X8_UNORM);
 
          vector unsigned int ifragZ;
index 235ac67c5307b22d95a8052448f50b4f3ef8ac7d..7341156310da648781d94fda4501e5bce3e59b6b 100644 (file)
@@ -93,7 +93,7 @@ i915_clear_emit(struct pipe_context *pipe, unsigned buffers,
       if (util_format_get_blocksize(depth_tex->b.b.format) == 4) {
          /* Avoid read-modify-write if there's no stencil. */
          if (buffers & PIPE_CLEAR_STENCIL
-               || depth_tex->b.b.format != PIPE_FORMAT_Z24_UNORM_S8_USCALED) {
+               || depth_tex->b.b.format != PIPE_FORMAT_Z24_UNORM_S8_UINT) {
             clear_params |= CLEARPARAM_WRITE_STENCIL;
             clear_stencil = packed_z_stencil & 0xff;
             clear_depth = packed_z_stencil;
@@ -110,7 +110,7 @@ i915_clear_emit(struct pipe_context *pipe, unsigned buffers,
 
       clear_params |= CLEARPARAM_WRITE_STENCIL;
       depth_tex = i915_texture(zbuf->texture);
-      assert(depth_tex->b.b.format == PIPE_FORMAT_Z24_UNORM_S8_USCALED);
+      assert(depth_tex->b.b.format == PIPE_FORMAT_Z24_UNORM_S8_UINT);
 
       packed_z_stencil = util_pack_z_stencil(depth_tex->b.b.format, depth, stencil);
       depth_clear_bbp = 32;
index 853d9f1917e8dbe6fdbc3f493ce4477a2172e91f..4e14b2fa5c65ef9c5807880170b94410ad135d8f 100644 (file)
@@ -293,7 +293,7 @@ i915_is_format_supported(struct pipe_screen *screen,
       PIPE_FORMAT_DXT3_RGBA,
       PIPE_FORMAT_DXT5_RGBA,
       PIPE_FORMAT_Z24X8_UNORM,
-      PIPE_FORMAT_Z24_UNORM_S8_USCALED,
+      PIPE_FORMAT_Z24_UNORM_S8_UINT,
       PIPE_FORMAT_NONE  /* list terminator */
    };
    static const enum pipe_format render_supported[] = {
@@ -310,7 +310,7 @@ i915_is_format_supported(struct pipe_screen *screen,
       /* XXX why not?
       PIPE_FORMAT_Z16_UNORM, */
       PIPE_FORMAT_Z24X8_UNORM,
-      PIPE_FORMAT_Z24_UNORM_S8_USCALED,
+      PIPE_FORMAT_Z24_UNORM_S8_UINT,
       PIPE_FORMAT_NONE  /* list terminator */
    };
    const enum pipe_format *list;
index 0103f7c35309fe44670d935efb9639bae020a0a8..5c74ffd7ee3df314016e665ce61af7746cad9cf1 100644 (file)
@@ -193,7 +193,7 @@ static uint translate_texture_format(enum pipe_format pipeFormat,
          view->swizzle_g != PIPE_SWIZZLE_GREEN ||
          view->swizzle_b != PIPE_SWIZZLE_BLUE ||
          view->swizzle_a != PIPE_SWIZZLE_ALPHA ) &&
-        pipeFormat != PIPE_FORMAT_Z24_UNORM_S8_USCALED &&
+        pipeFormat != PIPE_FORMAT_Z24_UNORM_S8_UINT &&
         pipeFormat != PIPE_FORMAT_Z24X8_UNORM )
       debug_printf("i915: unsupported texture swizzle for format %d\n", pipeFormat);
 
@@ -240,7 +240,7 @@ static uint translate_texture_format(enum pipe_format pipeFormat,
       return (MAPSURF_COMPRESSED | MT_COMPRESS_DXT2_3);
    case PIPE_FORMAT_DXT5_RGBA:
       return (MAPSURF_COMPRESSED | MT_COMPRESS_DXT4_5);
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
    case PIPE_FORMAT_Z24X8_UNORM:
       {
          if ( view->swizzle_r == PIPE_SWIZZLE_RED &&
index 1ef6a0d68b0de8d4bbbe66cda0c97db5ea5d7735..e462937c2733a8fe4c87bbf841250ebc08522fae 100644 (file)
@@ -64,7 +64,7 @@ static unsigned translate_depth_format(enum pipe_format zformat)
 {
    switch (zformat) {
    case PIPE_FORMAT_Z24X8_UNORM:
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       return DEPTH_FRMT_24_FIXED_8_OTHER;
    case PIPE_FORMAT_Z16_UNORM:
       return DEPTH_FRMT_16_FIXED;
index 4ba99a33d70404fca7e74ff93ab92e4e45feb8b0..731d2f6d988ad135b6671a48c2029ee8954e74d1 100644 (file)
@@ -251,7 +251,7 @@ i915_clear_depth_stencil_blitter(struct pipe_context *pipe,
       (otherwise this won't work anyway). Hence will only want to
       do it if really have stencil and it isn't cleared */
    if ((clear_flags & PIPE_CLEAR_STENCIL) ||
-       (dst->format != PIPE_FORMAT_Z24_UNORM_S8_USCALED))
+       (dst->format != PIPE_FORMAT_Z24_UNORM_S8_UINT))
       mask |= XY_COLOR_BLT_WRITE_ALPHA;
 
    i915_fill_blit( i915_context(pipe),
index d53ce6ccfd4a0041e3f9f1f9d65c6f5295cdd855..7d481a78433a431857be481e11ce974d9cd0655b 100644 (file)
@@ -266,7 +266,7 @@ static int emit_depthbuffer(struct brw_context *brw)
         cpp = 2;
         break;
       case PIPE_FORMAT_Z24X8_UNORM:
-      case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+      case PIPE_FORMAT_Z24_UNORM_S8_UINT:
         format = BRW_DEPTHFORMAT_D24_UNORM_S8_UINT;
         cpp = 4;
         break;
index 847b11565d4280718e754ab632964b56bf9b7874..759ef4c7dd99079b590fb119885129507ba8c667 100644 (file)
@@ -152,7 +152,7 @@ static void zstencil_clear(struct brw_context *brw,
       value = tmp.ui;
       break;
    case PIPE_FORMAT_Z24X8_UNORM:
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       value = ((unsigned)(depth * MASK24) & MASK24);
       break;
    case PIPE_FORMAT_Z16_UNORM:
@@ -171,7 +171,7 @@ static void zstencil_clear(struct brw_context *brw,
       value = value | (stencil << 24);
       mask |= XY_BLT_WRITE_ALPHA;
       break;
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       value = value | (stencil << 24);
       if (clear_flags & PIPE_CLEAR_STENCIL)
          mask |= XY_BLT_WRITE_ALPHA;
index 71a182902483ed65134a2087471ccc5de0a2ceab..630efcbd970e5742cd685d214550f50a5a8ca1ac 100644 (file)
@@ -176,7 +176,7 @@ static GLuint translate_tex_format( enum pipe_format pf )
    case PIPE_FORMAT_Z16_UNORM:
          return BRW_SURFACEFORMAT_I16_UNORM;
 
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
    case PIPE_FORMAT_Z24X8_UNORM:
          return BRW_SURFACEFORMAT_I24X8_UNORM;
 
index 076338ad5500d43593acc1ca193ac63d27ca09fe..deafd4b4ef0fdf4f341de4ac8cd5e90be831ba9d 100644 (file)
@@ -311,7 +311,7 @@ brw_is_format_supported(struct pipe_screen *screen,
       /* depth */
       PIPE_FORMAT_Z32_FLOAT,
       PIPE_FORMAT_Z24X8_UNORM,
-      PIPE_FORMAT_Z24_UNORM_S8_USCALED,
+      PIPE_FORMAT_Z24_UNORM_S8_UINT,
       PIPE_FORMAT_Z16_UNORM,
       /* signed */
       PIPE_FORMAT_R8G8_SNORM,
@@ -327,7 +327,7 @@ brw_is_format_supported(struct pipe_screen *screen,
    static const enum pipe_format depth_supported[] = {
       PIPE_FORMAT_Z32_FLOAT,
       PIPE_FORMAT_Z24X8_UNORM,
-      PIPE_FORMAT_Z24_UNORM_S8_USCALED,
+      PIPE_FORMAT_Z24_UNORM_S8_UINT,
       PIPE_FORMAT_Z16_UNORM,
       PIPE_FORMAT_NONE  /* list terminator */
    };
index 1bf741194c5ec6d4e4737f380d52874f3085ec13..5e0eb99c93703920f55515e5e28368a7aeb854f4 100644 (file)
@@ -521,8 +521,8 @@ lp_build_depth_stencil_test(struct gallivm_state *gallivm,
       assert(format_desc->block.height == 1);
 
       if (stencil[0].enabled) {
-         assert(format_desc->format == PIPE_FORMAT_Z24_UNORM_S8_USCALED ||
-                format_desc->format == PIPE_FORMAT_S8_USCALED_Z24_UNORM);
+         assert(format_desc->format == PIPE_FORMAT_Z24_UNORM_S8_UINT ||
+                format_desc->format == PIPE_FORMAT_S8_UINT_Z24_UNORM);
       }
 
       assert(z_swizzle < 4);
index 4e0e581326094a1038315735a6a541bb8090ac2f..488f8320738ef5de37b2c567f4d1a610575124f9 100644 (file)
@@ -115,7 +115,7 @@ const struct nv50_format nv50_format_table[PIPE_FORMAT_COUNT] =
     B_(C0, C0, C0, ONE_FLOAT, UNORM, UINT, UINT, UINT, Z16, 0),
     SAMPLER_VIEW | DEPTH_STENCIL },
 
-   [PIPE_FORMAT_Z24_UNORM_S8_USCALED] = { NV50_ZETA_FORMAT_Z24_S8_UNORM,
+   [PIPE_FORMAT_Z24_UNORM_S8_UINT] = { NV50_ZETA_FORMAT_Z24_S8_UNORM,
     B_(C0, C1, C0, ONE_FLOAT, UNORM, UINT, UINT, UINT, Z24_S8, 0),
     SAMPLER_VIEW | DEPTH_STENCIL },
 
@@ -123,7 +123,7 @@ const struct nv50_format nv50_format_table[PIPE_FORMAT_COUNT] =
     B_(C0, C0, C0, ONE_FLOAT, UNORM, UINT, UINT, UINT, Z24_X8, 0),
     SAMPLER_VIEW | DEPTH_STENCIL },
 
-   [PIPE_FORMAT_S8_USCALED_Z24_UNORM] = { NV50_ZETA_FORMAT_S8_Z24_UNORM,
+   [PIPE_FORMAT_S8_UINT_Z24_UNORM] = { NV50_ZETA_FORMAT_S8_Z24_UNORM,
     B_(C1, C0, C1, ONE_FLOAT, UINT, UNORM, UINT, UINT, S8_Z24, 0),
     SAMPLER_VIEW | DEPTH_STENCIL },
 
@@ -131,7 +131,7 @@ const struct nv50_format nv50_format_table[PIPE_FORMAT_COUNT] =
     B_(C0, C0, C0, ONE_FLOAT, FLOAT, UINT, UINT, UINT, Z32, 0),
     SAMPLER_VIEW | DEPTH_STENCIL },
 
-   [PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED] = { NV50_ZETA_FORMAT_Z32_S8_X24_FLOAT,
+   [PIPE_FORMAT_Z32_FLOAT_S8X24_UINT] = { NV50_ZETA_FORMAT_Z32_S8_X24_FLOAT,
     B_(C0, C0, C0, ONE_FLOAT, FLOAT, UINT, UINT, UINT, Z32_S8_X24, 0),
     SAMPLER_VIEW | DEPTH_STENCIL },
 
index 239be19d60458869957656e84a6d94e2a660751c..47090e119703d40990578c5c6490c5eee95bbc79 100644 (file)
@@ -48,17 +48,17 @@ nv50_mt_choose_storage_type(struct nv50_miptree *mt, boolean compressed)
    case PIPE_FORMAT_Z16_UNORM:
       tile_flags = 0x6c00 + (ms << 8);
       break;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
       tile_flags = 0x1800 + (ms << 8);
       break;
    case PIPE_FORMAT_Z24X8_UNORM:
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       tile_flags = 0x22800 + (ms << 8);
       break;
    case PIPE_FORMAT_Z32_FLOAT:
       tile_flags = 0x4000 + (ms << 8);
       break;
-   case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+   case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
       tile_flags = 0x6000 + (ms << 8);
       break;
    default:
index 83bb9434afa3e0c0864da9bf72d706b91803f7e0..910e18ff03c3e47a0891a0c349769dbb85dfb33f 100644 (file)
@@ -482,7 +482,7 @@ nv50_blitctx_make_fp(struct nv50_blitctx *blit)
 {
    static const uint32_t code[] =
    {
-      /* 3 coords RGBA in, RGBA out, also for Z32_FLOAT(_S8X24_USCALED) */
+      /* 3 coords RGBA in, RGBA out, also for Z32_FLOAT(_S8X24_UINT) */
       0x80000000, /* interp $r0 v[0x0] */
       0x80010004, /* interp $r1 v[0x4] */
       0x80020009, /* interp $r2 flat v[0x8] */
@@ -606,11 +606,11 @@ nv50_blit_zeta_to_colour_format(enum pipe_format format)
 {
    switch (format) {
    case PIPE_FORMAT_Z16_UNORM:               return PIPE_FORMAT_R16_UNORM;
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
    case PIPE_FORMAT_Z24X8_UNORM:             return PIPE_FORMAT_R8G8B8A8_UNORM;
    case PIPE_FORMAT_Z32_FLOAT:               return PIPE_FORMAT_R32_FLOAT;
-   case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED: return PIPE_FORMAT_R32G32_FLOAT;
+   case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT: return PIPE_FORMAT_R32G32_FLOAT;
    default:
       assert(0);
       return PIPE_FORMAT_NONE;
@@ -625,14 +625,14 @@ nv50_blitctx_get_color_mask_and_fp(struct nv50_blitctx *blit,
 
    switch (format) {
    case PIPE_FORMAT_Z24X8_UNORM:
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       blit->fp_offset = 160;
       if (mask & PIPE_MASK_Z)
          blit->color_mask |= 0x0111;
       if (mask & PIPE_MASK_S)
          blit->color_mask |= 0x1000;
       break;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
       blit->fp_offset = 24;
       if (mask & PIPE_MASK_Z)
          blit->color_mask |= 0x1110;
index 87d7fd8808305526daf90582ed6b800b373a9689..d30980450f4ce553ab41a559df60dd2595d513c2 100644 (file)
@@ -116,7 +116,7 @@ const struct nvc0_format nvc0_format_table[PIPE_FORMAT_COUNT] =
     B_(C0, C0, C0, ONE_FLOAT, UNORM, UINT, UINT, UINT, Z16, 0),
     SAMPLER_VIEW | DEPTH_STENCIL },
 
-   [PIPE_FORMAT_Z24_UNORM_S8_USCALED] = { NV50_ZETA_FORMAT_Z24_S8_UNORM,
+   [PIPE_FORMAT_Z24_UNORM_S8_UINT] = { NV50_ZETA_FORMAT_Z24_S8_UNORM,
     B_(C0, C0, C0, ONE_FLOAT, UNORM, UINT, UINT, UINT, Z24_S8, 0),
     SAMPLER_VIEW | DEPTH_STENCIL },
 
@@ -124,7 +124,7 @@ const struct nvc0_format nvc0_format_table[PIPE_FORMAT_COUNT] =
     B_(C0, C0, C0, ONE_FLOAT, UNORM, UINT, UINT, UINT, Z24_X8, 0),
     SAMPLER_VIEW | DEPTH_STENCIL },
 
-   [PIPE_FORMAT_S8_USCALED_Z24_UNORM] = { NV50_ZETA_FORMAT_S8_Z24_UNORM,
+   [PIPE_FORMAT_S8_UINT_Z24_UNORM] = { NV50_ZETA_FORMAT_S8_Z24_UNORM,
     B_(C1, C1, C1, ONE_FLOAT, UINT, UNORM, UINT, UINT, S8_Z24, 0),
     SAMPLER_VIEW | DEPTH_STENCIL },
 
@@ -132,7 +132,7 @@ const struct nvc0_format nvc0_format_table[PIPE_FORMAT_COUNT] =
     B_(C0, C0, C0, ONE_FLOAT, FLOAT, UINT, UINT, UINT, Z32, 0),
     SAMPLER_VIEW | DEPTH_STENCIL },
 
-   [PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED] = { NV50_ZETA_FORMAT_Z32_S8_X24_FLOAT,
+   [PIPE_FORMAT_Z32_FLOAT_S8X24_UINT] = { NV50_ZETA_FORMAT_Z32_S8_X24_FLOAT,
     B_(C0, C0, C0, ONE_FLOAT, FLOAT, UINT, UINT, UINT, Z32_S8_X24, 0),
     SAMPLER_VIEW | DEPTH_STENCIL },
 
index a72ddf306cd9338df661b7a351ac5b0d9b557308..6cdc8ab26905ff6a9fc0646a86fec5ca47bbd786 100644 (file)
@@ -75,14 +75,14 @@ nvc0_mt_choose_storage_type(struct nv50_miptree *mt, boolean compressed)
       else
          tile_flags = 0x0100;
       break;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
       if (compressed)
          tile_flags = 0x5100 + (ms << 8);
       else
          tile_flags = 0x4600;
       break;
    case PIPE_FORMAT_Z24X8_UNORM:
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       if (compressed)
          tile_flags = 0x1700 + (ms << 8);
       else
@@ -94,7 +94,7 @@ nvc0_mt_choose_storage_type(struct nv50_miptree *mt, boolean compressed)
       else
          tile_flags = 0x7b00;
       break;
-   case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+   case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
       if (compressed)
          tile_flags = 0xce00 + (ms << 8);
       else
index ff07aad00d00ffc5430acfc4e2d2b9463b046824..f1302b473bcb6a04d4a1a13bf1837fb8db06e11a 100644 (file)
@@ -478,7 +478,7 @@ nvc0_blitctx_make_fp(struct nvc0_blitctx *blit)
 {
    static const uint32_t code[] = /* use nvc0dis */
    {
-      /* 2 coords RGBA in, RGBA out, also for Z32_FLOAT(_S8X24_USCALED)
+      /* 2 coords RGBA in, RGBA out, also for Z32_FLOAT(_S8X24_UINT)
        * NOTE:
        * NVC0 doesn't like tex 3d on non-3d textures, but there should
        * only be 2d and 2d-array MS resources anyway.
@@ -581,11 +581,11 @@ nvc0_blit_zeta_to_colour_format(enum pipe_format format)
 {
    switch (format) {
    case PIPE_FORMAT_Z16_UNORM:               return PIPE_FORMAT_R16_UNORM;
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
    case PIPE_FORMAT_Z24X8_UNORM:             return PIPE_FORMAT_R8G8B8A8_UNORM;
    case PIPE_FORMAT_Z32_FLOAT:               return PIPE_FORMAT_R32_FLOAT;
-   case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED: return PIPE_FORMAT_R32G32_FLOAT;
+   case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:    return PIPE_FORMAT_R32G32_FLOAT;
    default:
       assert(0);
       return PIPE_FORMAT_NONE;
@@ -600,14 +600,14 @@ nvc0_blitctx_get_color_mask_and_fp(struct nvc0_blitctx *blit,
 
    switch (format) {
    case PIPE_FORMAT_Z24X8_UNORM:
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       blit->fp_offset = 0x180;
       if (mask & PIPE_MASK_Z)
          blit->color_mask |= 0x0111;
       if (mask & PIPE_MASK_S)
          blit->color_mask |= 0x1000;
       break;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
       blit->fp_offset = 0x80;
       if (mask & PIPE_MASK_Z)
          blit->color_mask |= 0x1110;
index 3ef9fcce347e8507b9fcbfbf51b24f492a2586e7..cb87539f61b12f847d2afb7dc8f5a020766344e2 100644 (file)
@@ -345,7 +345,7 @@ nvfx_texture_formats[PIPE_FORMAT_COUNT] = {
        _(DXT5_SRGBA,           DXT5,           T, T, T, T, X, Y, Z, W, UNORM, SRGB),
 
        __(Z16_UNORM,           A8L8, Z16,      T, T, T, 1, W, W, W, W, UNORM, 0),
-       __(S8_USCALED_Z24_UNORM,HILO16,Z24,     T, T, T, 1, W, W, W, W, UNORM, 0),
+       __(S8_UINT_Z24_UNORM,HILO16,Z24,        T, T, T, 1, W, W, W, W, UNORM, 0),
        __(X8Z24_UNORM,         HILO16,Z24,     T, T, T, 1, W, W, W, W, UNORM, 0),
 
        _(R16_UNORM,            A16,            T, 0, 0, 1, X, X, X, X, UNORM, 0),
index 50f346700d8f7d08f7a98c0b64c06b9f8ca399f0..6086d43e1c08f66c78e5cee7952d35c136481bad 100644 (file)
@@ -269,7 +269,7 @@ nvfx_screen_is_format_supported(struct pipe_screen *pscreen,
 
        if (bind & PIPE_BIND_DEPTH_STENCIL) {
                switch (format) {
-               case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+               case PIPE_FORMAT_S8_UINT_Z24_UNORM:
                case PIPE_FORMAT_X8Z24_UNORM:
                case PIPE_FORMAT_Z16_UNORM:
                        break;
index dc4ab2f984e7ce47b3991abaa8a8bab1bdc3b451..406f5bbde9d6a51acdcb97b026c8401a43801b04 100644 (file)
@@ -171,7 +171,7 @@ nvfx_framebuffer_validate(struct nvfx_context *nvfx, unsigned prepare_result)
                case PIPE_FORMAT_Z16_UNORM:
                        rt_format |= NV30_3D_RT_FORMAT_ZETA_Z16;
                        break;
-               case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+               case PIPE_FORMAT_S8_UINT_Z24_UNORM:
                case PIPE_FORMAT_X8Z24_UNORM:
                case 0:
                        rt_format |= NV30_3D_RT_FORMAT_ZETA_Z24S8;
index d1ccde1a9cbf2a0b60f8a6ba9e1679a8e0b2244f..3974aea878fc7a40b95437dec4b00aca75550ff4 100644 (file)
@@ -155,7 +155,7 @@ static uint32_t r300_depth_clear_value(enum pipe_format format,
         case PIPE_FORMAT_X8Z24_UNORM:
             return util_pack_z(format, depth);
 
-        case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+        case PIPE_FORMAT_S8_UINT_Z24_UNORM:
             return util_pack_z_stencil(format, depth, stencil);
 
         default:
index 9ba6397084a1d1bc4dfb39c6af351a979155ab84..c1e25c63ba67730c44411afb433ea159b0d561e3 100644 (file)
@@ -615,7 +615,7 @@ static uint32_t r300_get_border_color(enum pipe_format format,
         case PIPE_FORMAT_Z16_UNORM:
             return util_pack_z(PIPE_FORMAT_Z16_UNORM, border[0]);
         case PIPE_FORMAT_X8Z24_UNORM:
-        case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+        case PIPE_FORMAT_S8_UINT_Z24_UNORM:
             if (is_r500) {
                 return util_pack_z(PIPE_FORMAT_X8Z24_UNORM, border[0]);
             } else {
index 864dbc2e7bb6490733338eba5ab72766220730ab..34860c9d72b5c509b378c3650931d6d1ca2bb239 100644 (file)
@@ -129,7 +129,7 @@ uint32_t r300_translate_texformat(enum pipe_format format,
                 case PIPE_FORMAT_Z16_UNORM:
                     return R300_TX_FORMAT_X16;
                 case PIPE_FORMAT_X8Z24_UNORM:
-                case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+                case PIPE_FORMAT_S8_UINT_Z24_UNORM:
                     if (is_r500)
                         return R500_TX_FORMAT_Y8X24;
                     else
@@ -374,7 +374,7 @@ uint32_t r500_tx_format_msb_bit(enum pipe_format format)
         case PIPE_FORMAT_LATC1_UNORM:
         case PIPE_FORMAT_LATC1_SNORM:
         case PIPE_FORMAT_X8Z24_UNORM:
-        case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+        case PIPE_FORMAT_S8_UINT_Z24_UNORM:
             return R500_TXFORMAT_MSB;
         default:
             return 0;
@@ -492,7 +492,7 @@ static uint32_t r300_translate_zsformat(enum pipe_format format)
         /* 24-bit depth, ignored stencil */
         case PIPE_FORMAT_X8Z24_UNORM:
         /* 24-bit depth, 8-bit stencil */
-        case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+        case PIPE_FORMAT_S8_UINT_Z24_UNORM:
             return R300_DEPTHFORMAT_24BIT_INT_Z_8BIT_STENCIL;
         default:
             return ~0; /* Unsupported. */
index 92600f8d6d6a83447e8dafdb3906d8e8f07bf786..23a3c4f445265d56439fafd35ccfad8e80105f28 100644 (file)
@@ -262,10 +262,10 @@ static uint32_t r600_translate_dbformat(enum pipe_format format)
        case PIPE_FORMAT_Z16_UNORM:
                return V_028040_Z_16;
        case PIPE_FORMAT_Z24X8_UNORM:
-       case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+       case PIPE_FORMAT_Z24_UNORM_S8_UINT:
                return V_028040_Z_24;
        case PIPE_FORMAT_Z32_FLOAT:
-       case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+       case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
                return V_028040_Z_32_FLOAT;
        default:
                return ~0U;
@@ -355,11 +355,11 @@ static uint32_t r600_translate_colorswap(enum pipe_format format)
                return V_028C70_SWAP_STD_REV;
 
        case PIPE_FORMAT_Z24X8_UNORM:
-       case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+       case PIPE_FORMAT_Z24_UNORM_S8_UINT:
                return V_028C70_SWAP_STD;
 
        case PIPE_FORMAT_X8Z24_UNORM:
-       case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+       case PIPE_FORMAT_S8_UINT_Z24_UNORM:
                return V_028C70_SWAP_STD;
 
        case PIPE_FORMAT_R10G10B10A2_UNORM:
@@ -392,7 +392,7 @@ static uint32_t r600_translate_colorswap(enum pipe_format format)
        case PIPE_FORMAT_R16G16B16A16_UINT:
        case PIPE_FORMAT_R16G16B16A16_SINT:
        case PIPE_FORMAT_R16G16B16A16_FLOAT:
-       case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+       case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
 
        /* 128-bit buffers. */
        case PIPE_FORMAT_R32G32B32A32_FLOAT:
@@ -494,14 +494,14 @@ static uint32_t r600_translate_colorformat(enum pipe_format format)
                return V_028C70_COLOR_2_10_10_10;
 
        case PIPE_FORMAT_Z24X8_UNORM:
-       case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+       case PIPE_FORMAT_Z24_UNORM_S8_UINT:
                return V_028C70_COLOR_8_24;
 
        case PIPE_FORMAT_X8Z24_UNORM:
-       case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+       case PIPE_FORMAT_S8_UINT_Z24_UNORM:
                return V_028C70_COLOR_24_8;
 
-       case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+       case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
                return V_028C70_COLOR_X24_8_32_FLOAT;
 
        case PIPE_FORMAT_R32_FLOAT:
@@ -2197,12 +2197,12 @@ void evergreen_polygon_offset_update(struct r600_pipe_context *rctx)
 
                switch (rctx->framebuffer.zsbuf->texture->format) {
                case PIPE_FORMAT_Z24X8_UNORM:
-               case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+               case PIPE_FORMAT_Z24_UNORM_S8_UINT:
                        depth = -24;
                        offset_units *= 2.0f;
                        break;
                case PIPE_FORMAT_Z32_FLOAT:
-               case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+               case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
                        depth = -23;
                        offset_units *= 1.0f;
                        offset_db_fmt_cntl |= S_028B78_POLY_OFFSET_DB_IS_FLOAT_FMT(1);
index 23f308682e835dd25215947afb1af820b0617515..03e6958d5661684f62129cd7cbe7999c2c08deab 100644 (file)
@@ -261,11 +261,11 @@ static uint32_t r600_translate_dbformat(enum pipe_format format)
                return V_028010_DEPTH_16;
        case PIPE_FORMAT_Z24X8_UNORM:
                return V_028010_DEPTH_X8_24;
-       case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+       case PIPE_FORMAT_Z24_UNORM_S8_UINT:
                return V_028010_DEPTH_8_24;
        case PIPE_FORMAT_Z32_FLOAT:
                return V_028010_DEPTH_32_FLOAT;
-       case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+       case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
                return V_028010_DEPTH_X24_8_32_FLOAT;
        default:
                return ~0U;
@@ -356,11 +356,11 @@ static uint32_t r600_translate_colorswap(enum pipe_format format)
                return V_0280A0_SWAP_STD_REV;
 
        case PIPE_FORMAT_Z24X8_UNORM:
-       case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+       case PIPE_FORMAT_Z24_UNORM_S8_UINT:
                return V_0280A0_SWAP_STD;
 
        case PIPE_FORMAT_X8Z24_UNORM:
-       case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+       case PIPE_FORMAT_S8_UINT_Z24_UNORM:
                return V_0280A0_SWAP_STD;
 
        case PIPE_FORMAT_R10G10B10A2_UNORM:
@@ -393,7 +393,7 @@ static uint32_t r600_translate_colorswap(enum pipe_format format)
        case PIPE_FORMAT_R16G16B16A16_UINT:
        case PIPE_FORMAT_R16G16B16A16_SINT:
        case PIPE_FORMAT_R16G16B16A16_FLOAT:
-       case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+       case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
 
        /* 128-bit buffers. */
        case PIPE_FORMAT_R32G32B32A32_FLOAT:
@@ -495,14 +495,14 @@ static uint32_t r600_translate_colorformat(enum pipe_format format)
                return V_0280A0_COLOR_2_10_10_10;
 
        case PIPE_FORMAT_Z24X8_UNORM:
-       case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+       case PIPE_FORMAT_Z24_UNORM_S8_UINT:
                return V_0280A0_COLOR_8_24;
 
        case PIPE_FORMAT_X8Z24_UNORM:
-       case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+       case PIPE_FORMAT_S8_UINT_Z24_UNORM:
                return V_0280A0_COLOR_24_8;
 
-       case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+       case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
                return V_0280A0_COLOR_X24_8_32_FLOAT;
 
        case PIPE_FORMAT_R32_FLOAT:
@@ -703,12 +703,12 @@ void r600_polygon_offset_update(struct r600_pipe_context *rctx)
 
                switch (rctx->framebuffer.zsbuf->texture->format) {
                case PIPE_FORMAT_Z24X8_UNORM:
-               case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+               case PIPE_FORMAT_Z24_UNORM_S8_UINT:
                        depth = -24;
                        offset_units *= 2.0f;
                        break;
                case PIPE_FORMAT_Z32_FLOAT:
-               case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+               case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
                        depth = -23;
                        offset_units *= 1.0f;
                        offset_db_fmt_cntl |= S_028DF8_POLY_OFFSET_DB_IS_FLOAT_FMT(1);
index acb181139bf596e7e7212aa63a6e3d4ecdf1a019..1682cc877c96c5546e13605a26b642b01f38d672 100644 (file)
@@ -401,13 +401,13 @@ r600_texture_create_object(struct pipe_screen *screen,
                unsigned stencil_pitch_override = 0;
 
                switch (base->format) {
-               case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+               case PIPE_FORMAT_Z24_UNORM_S8_UINT:
                        rtex->real_format = PIPE_FORMAT_Z24X8_UNORM;
                        break;
-               case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+               case PIPE_FORMAT_S8_UINT_Z24_UNORM:
                        rtex->real_format = PIPE_FORMAT_X8Z24_UNORM;
                        break;
-               case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+               case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
                        rtex->real_format = PIPE_FORMAT_Z32_FLOAT;
                        break;
                default:
@@ -418,14 +418,14 @@ r600_texture_create_object(struct pipe_screen *screen,
 
                /* Divide the pitch in bytes by 4 for stencil, because it has a smaller pixel size. */
                if (pitch_in_bytes_override) {
-                       assert(base->format == PIPE_FORMAT_Z24_UNORM_S8_USCALED ||
-                              base->format == PIPE_FORMAT_S8_USCALED_Z24_UNORM);
+                       assert(base->format == PIPE_FORMAT_Z24_UNORM_S8_UINT ||
+                              base->format == PIPE_FORMAT_S8_UINT_Z24_UNORM);
                        stencil_pitch_override = pitch_in_bytes_override / 4;
                }
 
                /* Allocate the stencil buffer. */
                stencil = *base;
-               stencil.format = PIPE_FORMAT_S8_USCALED;
+               stencil.format = PIPE_FORMAT_S8_UINT;
                rtex->stencil = r600_texture_create_object(screen, &stencil, array_mode,
                                                           stencil_pitch_override,
                                                           max_buffer_size, NULL, FALSE);
@@ -882,26 +882,26 @@ uint32_t r600_translate_texformat(struct pipe_screen *screen,
                case PIPE_FORMAT_Z16_UNORM:
                        result = FMT_16;
                        goto out_word4;
-               case PIPE_FORMAT_X24S8_USCALED:
+               case PIPE_FORMAT_X24S8_UINT:
                        word4 |= S_038010_NUM_FORMAT_ALL(V_038010_SQ_NUM_FORMAT_INT);
                case PIPE_FORMAT_Z24X8_UNORM:
-               case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+               case PIPE_FORMAT_Z24_UNORM_S8_UINT:
                        result = FMT_8_24;
                        goto out_word4;
-               case PIPE_FORMAT_S8X24_USCALED:
+               case PIPE_FORMAT_S8X24_UINT:
                        word4 |= S_038010_NUM_FORMAT_ALL(V_038010_SQ_NUM_FORMAT_INT);
                case PIPE_FORMAT_X8Z24_UNORM:
-               case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+               case PIPE_FORMAT_S8_UINT_Z24_UNORM:
                        result = FMT_24_8;
                        goto out_word4;
-               case PIPE_FORMAT_S8_USCALED:
+               case PIPE_FORMAT_S8_UINT:
                        result = FMT_8;
                        word4 |= S_038010_NUM_FORMAT_ALL(V_038010_SQ_NUM_FORMAT_INT);
                        goto out_word4;
                case PIPE_FORMAT_Z32_FLOAT:
                        result = FMT_32_FLOAT;
                        goto out_word4;
-               case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+               case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
                        result = FMT_X24_8_32_FLOAT;
                        goto out_word4;
                default:
index a349f0d1f3c9e5a2c937967d661bcd248d67760b..29fb59955e4a4d888a94b6f7c932fcdddb149570 100644 (file)
@@ -77,7 +77,7 @@ get_depth_stencil_values( struct depth_data *data,
       }
       break;
    case PIPE_FORMAT_Z24X8_UNORM:
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       for (j = 0; j < QUAD_SIZE; j++) {
          int x = quad->input.x0 % TILE_SIZE + (j & 1);
          int y = quad->input.y0 % TILE_SIZE + (j >> 1);
@@ -86,7 +86,7 @@ get_depth_stencil_values( struct depth_data *data,
       }
       break;
    case PIPE_FORMAT_X8Z24_UNORM:
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
       for (j = 0; j < QUAD_SIZE; j++) {
          int x = quad->input.x0 % TILE_SIZE + (j & 1);
          int y = quad->input.y0 % TILE_SIZE + (j >> 1);
@@ -94,7 +94,7 @@ get_depth_stencil_values( struct depth_data *data,
          data->stencilVals[j] = tile->data.depth32[y][x] & 0xff;
       }
       break;
-   case PIPE_FORMAT_S8_USCALED:
+   case PIPE_FORMAT_S8_UINT:
       for (j = 0; j < QUAD_SIZE; j++) {
          int x = quad->input.x0 % TILE_SIZE + (j & 1);
          int y = quad->input.y0 % TILE_SIZE + (j >> 1);
@@ -163,7 +163,7 @@ convert_quad_depth( struct depth_data *data,
       }
       break;
    case PIPE_FORMAT_Z24X8_UNORM:
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       {
          float scale = (float) ((1 << 24) - 1);
 
@@ -173,7 +173,7 @@ convert_quad_depth( struct depth_data *data,
       }
       break;
    case PIPE_FORMAT_X8Z24_UNORM:
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
       {
          float scale = (float) ((1 << 24) - 1);
 
@@ -203,10 +203,10 @@ convert_quad_stencil( struct depth_data *data,
     */
    switch (data->format) {
    case PIPE_FORMAT_Z24X8_UNORM:
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
    case PIPE_FORMAT_X8Z24_UNORM:
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
-   case PIPE_FORMAT_S8_USCALED:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT:
       for (j = 0; j < QUAD_SIZE; j++) {
          data->shader_stencil_refs[j] = ((unsigned)(quad->output.stencil[j]));
       }
@@ -244,14 +244,14 @@ write_depth_stencil_values( struct depth_data *data,
          tile->data.depth32[y][x] = data->bzzzz[j];
       }
       break;
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       for (j = 0; j < QUAD_SIZE; j++) {
          int x = quad->input.x0 % TILE_SIZE + (j & 1);
          int y = quad->input.y0 % TILE_SIZE + (j >> 1);
          tile->data.depth32[y][x] = (data->stencilVals[j] << 24) | data->bzzzz[j];
       }
       break;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
       for (j = 0; j < QUAD_SIZE; j++) {
          int x = quad->input.x0 % TILE_SIZE + (j & 1);
          int y = quad->input.y0 % TILE_SIZE + (j >> 1);
@@ -265,7 +265,7 @@ write_depth_stencil_values( struct depth_data *data,
          tile->data.depth32[y][x] = data->bzzzz[j] << 8;
       }
       break;
-   case PIPE_FORMAT_S8_USCALED:
+   case PIPE_FORMAT_S8_UINT:
       for (j = 0; j < QUAD_SIZE; j++) {
          int x = quad->input.x0 % TILE_SIZE + (j & 1);
          int y = quad->input.y0 % TILE_SIZE + (j >> 1);
index 416612d120dab6b99da029cc6f6c2d979955d557..374f54d9778579fb793a06ca8ea4fa722490a606 100644 (file)
@@ -68,7 +68,7 @@ svga_translate_format(struct svga_screen *ss,
 
    case PIPE_FORMAT_Z16_UNORM:
       return bind & PIPE_BIND_SAMPLER_VIEW ? ss->depth.z16 : SVGA3D_Z_D16;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
       return bind & PIPE_BIND_SAMPLER_VIEW ? ss->depth.s8z24 : SVGA3D_Z_D24S8;
    case PIPE_FORMAT_X8Z24_UNORM:
       return bind & PIPE_BIND_SAMPLER_VIEW ? ss->depth.x8z24 : SVGA3D_Z_D24X8;
index ddee9ee5d7322e7f54f5a8eaff891d1af136122e..89a66f65e7c67fca4cedc249dc8e56f7c96ec705 100644 (file)
@@ -71,7 +71,7 @@ try_clear(struct svga_context *svga,
       if (buffers & PIPE_CLEAR_DEPTH)
          flags |= SVGA3D_CLEAR_DEPTH;
 
-      if ((svga->curr.framebuffer.zsbuf->format == PIPE_FORMAT_S8_USCALED_Z24_UNORM) &&
+      if ((svga->curr.framebuffer.zsbuf->format == PIPE_FORMAT_S8_UINT_Z24_UNORM) &&
           (buffers & PIPE_CLEAR_STENCIL))
          flags |= SVGA3D_CLEAR_STENCIL;
 
index 440919c6262ee2fd403eabec1603874af7aeccc2..603c95373d42d4cb35ac45be87a54fb4bb06d6f2 100644 (file)
@@ -118,9 +118,9 @@ static void svga_set_framebuffer_state(struct pipe_context *pipe,
       case PIPE_FORMAT_Z16_UNORM:
          svga->curr.depthscale = 1.0f / DEPTH_BIAS_SCALE_FACTOR_D16;
          break;
-      case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+      case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       case PIPE_FORMAT_Z24X8_UNORM:
-      case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+      case PIPE_FORMAT_S8_UINT_Z24_UNORM:
       case PIPE_FORMAT_X8Z24_UNORM:
          svga->curr.depthscale = 1.0f / DEPTH_BIAS_SCALE_FACTOR_D24S8;
          break;
index 502f21fc42c82679903b9a9c9e3d7d372a88a257..93f8f6a951d8a7b4e35eb7521fa6da46f69635b0 100644 (file)
@@ -74,7 +74,7 @@ static int emit_framebuffer( struct svga_context *svga,
          return ret;
 
       if (curr->zsbuf &&
-          curr->zsbuf->format == PIPE_FORMAT_S8_USCALED_Z24_UNORM) {
+          curr->zsbuf->format == PIPE_FORMAT_S8_UINT_Z24_UNORM) {
          ret = SVGA3D_SetRenderTarget(svga->swc, SVGA3D_RT_STENCIL, curr->zsbuf);
          if (ret != PIPE_OK)
             return ret;
@@ -127,7 +127,7 @@ svga_reemit_framebuffer_bindings(struct svga_context *svga)
       }
 
       if (hw->zsbuf &&
-          hw->zsbuf->format == PIPE_FORMAT_S8_USCALED_Z24_UNORM) {
+          hw->zsbuf->format == PIPE_FORMAT_S8_UINT_Z24_UNORM) {
          ret = SVGA3D_SetRenderTarget(svga->swc, SVGA3D_RT_STENCIL, hw->zsbuf);
          if (ret != PIPE_OK) {
             return ret;
index 1b8ad97d4982ebd7ca9bb524be51562ecbdbb9ea..e32dace01f3d308d7f2c5432b97d2e7049db4c49 100644 (file)
@@ -71,11 +71,11 @@ enum pipe_format {
    PIPE_FORMAT_Z16_UNORM               = 16,
    PIPE_FORMAT_Z32_UNORM               = 17,
    PIPE_FORMAT_Z32_FLOAT               = 18,
-   PIPE_FORMAT_Z24_UNORM_S8_USCALED    = 19,
-   PIPE_FORMAT_S8_USCALED_Z24_UNORM    = 20,
+   PIPE_FORMAT_Z24_UNORM_S8_UINT       = 19,
+   PIPE_FORMAT_S8_UINT_Z24_UNORM       = 20,
    PIPE_FORMAT_Z24X8_UNORM             = 21,
    PIPE_FORMAT_X8Z24_UNORM             = 22,
-   PIPE_FORMAT_S8_USCALED              = 23,   /**< ubyte stencil */
+   PIPE_FORMAT_S8_UINT                 = 23,   /**< ubyte stencil */
    PIPE_FORMAT_R64_FLOAT               = 24,
    PIPE_FORMAT_R64G64_FLOAT            = 25,
    PIPE_FORMAT_R64G64B64_FLOAT         = 26,
@@ -185,7 +185,7 @@ enum pipe_format {
    PIPE_FORMAT_R10G10B10A2_USCALED     = 123,
    PIPE_FORMAT_R11G11B10_FLOAT         = 124,
    PIPE_FORMAT_R9G9B9E5_FLOAT          = 125,
-   PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED = 126,
+   PIPE_FORMAT_Z32_FLOAT_S8X24_UINT    = 126,
    PIPE_FORMAT_R1_UNORM                = 127,
    PIPE_FORMAT_R10G10B10X2_USCALED     = 128,
    PIPE_FORMAT_R10G10B10X2_SNORM       = 129,
@@ -197,9 +197,9 @@ enum pipe_format {
    PIPE_FORMAT_B4G4R4X4_UNORM          = 135,
 
    /* some stencil samplers formats */
-   PIPE_FORMAT_X24S8_USCALED           = 136,
-   PIPE_FORMAT_S8X24_USCALED           = 137,
-   PIPE_FORMAT_X32_S8X24_USCALED       = 138,
+   PIPE_FORMAT_X24S8_UINT              = 136,
+   PIPE_FORMAT_S8X24_UINT              = 137,
+   PIPE_FORMAT_X32_S8X24_UINT          = 138,
 
    PIPE_FORMAT_B2G3R3_UNORM            = 139,
    PIPE_FORMAT_L16A16_UNORM            = 140,
index da28e64384897aecb404429c6a494d7f55733a2f..a6a8eb7022a18d41e31ca1a9456b15f14db676bc 100644 (file)
@@ -50,10 +50,10 @@ pipe_format dxgi_to_pipe_format[DXGI_FORMAT_COUNT] =
        PIPE_FORMAT_R32G32_FLOAT,
        PIPE_FORMAT_R32G32_USCALED,
        PIPE_FORMAT_R32G32_SSCALED,
-       PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED, /* PIPE_FORMAT_R32G8X24_FLOAT_TYPELESS */
-       PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED,
-       PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED, /* PIPE_FORMAT_R32_FLOAT_X8X24_TYPELESS */
-       PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED, /* PIPE_FORMAT_X32_TYPELESS_G8X24_USCALED */
+       PIPE_FORMAT_Z32_FLOAT_S8X24_UINT, /* PIPE_FORMAT_R32G8X24_FLOAT_TYPELESS */
+       PIPE_FORMAT_Z32_FLOAT_S8X24_UINT,
+       PIPE_FORMAT_Z32_FLOAT_S8X24_UINT, /* PIPE_FORMAT_R32_FLOAT_X8X24_TYPELESS */
+       PIPE_FORMAT_Z32_FLOAT_S8X24_UINT, /* PIPE_FORMAT_X32_TYPELESS_G8X24_UINT */
        PIPE_FORMAT_R10G10B10A2_UNORM, /* TYPELESS */
        PIPE_FORMAT_R10G10B10A2_UNORM,
        PIPE_FORMAT_R10G10B10A2_USCALED,
@@ -75,10 +75,10 @@ pipe_format dxgi_to_pipe_format[DXGI_FORMAT_COUNT] =
        PIPE_FORMAT_R32_FLOAT,
        PIPE_FORMAT_R32_USCALED,
        PIPE_FORMAT_R32_SSCALED,
-       PIPE_FORMAT_Z24_UNORM_S8_USCALED, /* PIPE_FORMAT_R24G8_TYPELESS */
-       PIPE_FORMAT_Z24_UNORM_S8_USCALED,
+       PIPE_FORMAT_Z24_UNORM_S8_UINT, /* PIPE_FORMAT_R24G8_TYPELESS */
+       PIPE_FORMAT_Z24_UNORM_S8_UINT,
        PIPE_FORMAT_Z24X8_UNORM, /* PIPE_FORMAT_R24_UNORM_X8_TYPELESS */
-       PIPE_FORMAT_Z24_UNORM_S8_USCALED, /* PIPE_FORMAT_X24_TYPELESS_G8_USCALED */
+       PIPE_FORMAT_Z24_UNORM_S8_UINT, /* PIPE_FORMAT_X24_TYPELESS_G8_UINT */
        PIPE_FORMAT_R8G8_UNORM, /* TYPELESS */
        PIPE_FORMAT_R8G8_UNORM,
        PIPE_FORMAT_R8G8_USCALED,
index dcb6fdf8f3c0b209fb0dc7a8923346ccbe141ec6..8568eaea6741fdd314f401916674ab03d36c9dbf 100644 (file)
@@ -95,10 +95,10 @@ dri_fill_in_modes(struct dri_screen *screen,
    pf_z24x8 = p_screen->is_format_supported(p_screen, PIPE_FORMAT_X8Z24_UNORM,
                                            PIPE_TEXTURE_2D, 0,
                                             PIPE_BIND_DEPTH_STENCIL);
-   pf_s8z24 = p_screen->is_format_supported(p_screen, PIPE_FORMAT_Z24_UNORM_S8_USCALED,
+   pf_s8z24 = p_screen->is_format_supported(p_screen, PIPE_FORMAT_Z24_UNORM_S8_UINT,
                                            PIPE_TEXTURE_2D, 0,
                                             PIPE_BIND_DEPTH_STENCIL);
-   pf_z24s8 = p_screen->is_format_supported(p_screen, PIPE_FORMAT_S8_USCALED_Z24_UNORM,
+   pf_z24s8 = p_screen->is_format_supported(p_screen, PIPE_FORMAT_S8_UINT_Z24_UNORM,
                                            PIPE_TEXTURE_2D, 0,
                                             PIPE_BIND_DEPTH_STENCIL);
    pf_a8r8g8b8 = p_screen->is_format_supported(p_screen, PIPE_FORMAT_B8G8R8A8_UNORM,
@@ -270,8 +270,8 @@ dri_fill_st_visual(struct st_visual *stvis, struct dri_screen *screen,
                                           PIPE_FORMAT_X8Z24_UNORM;
       } else {
         stvis->depth_stencil_format = (screen->sd_depth_bits_last) ?
-                                          PIPE_FORMAT_Z24_UNORM_S8_USCALED:
-                                          PIPE_FORMAT_S8_USCALED_Z24_UNORM;
+                                          PIPE_FORMAT_Z24_UNORM_S8_UINT:
+                                          PIPE_FORMAT_S8_UINT_Z24_UNORM;
       }
       break;
    case 32:
index 4cab4b23d42f968e22ffe0233f4283d3c4a77c98..182ce684ecd13e99e7055b919f3be1c52e200b78 100644 (file)
@@ -386,7 +386,7 @@ egl_g3d_fill_depth_stencil_formats(_EGLDisplay *dpy,
    const EGLint candidates[] = {
       1, PIPE_FORMAT_Z16_UNORM,
       1, PIPE_FORMAT_Z32_UNORM,
-      2, PIPE_FORMAT_Z24_UNORM_S8_USCALED, PIPE_FORMAT_S8_USCALED_Z24_UNORM,
+      2, PIPE_FORMAT_Z24_UNORM_S8_UINT, PIPE_FORMAT_S8_UINT_Z24_UNORM,
       2, PIPE_FORMAT_Z24X8_UNORM, PIPE_FORMAT_X8Z24_UNORM,
       0
    };
index 8f6406ddaee20c469523c84b9ca9936260904d7c..ed786caaa43f1a5e5f4093d48aa65d78b312bdee 100644 (file)
@@ -391,8 +391,8 @@ choose_depth_stencil_format(XMesaDisplay xmdpy, int depth, int stencil)
       formats[count++] = PIPE_FORMAT_Z24X8_UNORM;
    }
    if (depth <= 24 && stencil <= 8) {
-      formats[count++] = PIPE_FORMAT_S8_USCALED_Z24_UNORM;
-      formats[count++] = PIPE_FORMAT_Z24_UNORM_S8_USCALED;
+      formats[count++] = PIPE_FORMAT_S8_UINT_Z24_UNORM;
+      formats[count++] = PIPE_FORMAT_Z24_UNORM_S8_UINT;
    }
    if (depth <= 32 && stencil == 0) {
       formats[count++] = PIPE_FORMAT_Z32_UNORM;
index 8d22bb27cf7d9e3b17509e3bae0fd05c725bc238..ca4ec7f82bafefc0c8d02e2f1777960aa65eb2d5 100644 (file)
@@ -61,8 +61,8 @@ choose_depth_stencil_format(struct vg_context *ctx)
 {
    struct pipe_screen *screen = ctx->pipe->screen;
    enum pipe_format formats[] = {
-      PIPE_FORMAT_Z24_UNORM_S8_USCALED,
-      PIPE_FORMAT_S8_USCALED_Z24_UNORM,
+      PIPE_FORMAT_Z24_UNORM_S8_UINT,
+      PIPE_FORMAT_S8_UINT_Z24_UNORM,
       PIPE_FORMAT_NONE
    };
    enum pipe_format *fmt;
index 333f50c25f6114bb288d10b62569b6492c095cc3..ec044319e2c41e419f22254f7108d2042cc81a5e 100644 (file)
@@ -94,8 +94,8 @@ stw_pf_depth_stencil[] = {
    { PIPE_FORMAT_Z24X8_UNORM, {24, 0} },
    { PIPE_FORMAT_Z16_UNORM,   {16, 0} },
    /* combined depth-stencil */
-   { PIPE_FORMAT_Z24_UNORM_S8_USCALED, {24, 8} },
-   { PIPE_FORMAT_S8_USCALED_Z24_UNORM, {24, 8} }
+   { PIPE_FORMAT_Z24_UNORM_S8_UINT, {24, 8} },
+   { PIPE_FORMAT_S8_UINT_Z24_UNORM, {24, 8} }
 };
 
 
index 01879ff6da0839d1246d1a9433958e2532efa666..50bf4b7e00c06133c9733b17494a6d3e0ce06574 100644 (file)
@@ -118,10 +118,10 @@ xa_get_pipe_format(enum xa_formats xa_format)
        fdesc.format = PIPE_FORMAT_X8Z24_UNORM;
        break;
     case xa_format_s8z24:
-       fdesc.format = PIPE_FORMAT_Z24_UNORM_S8_USCALED;
+       fdesc.format = PIPE_FORMAT_Z24_UNORM_S8_UINT;
        break;
     case xa_format_z24s8:
-       fdesc.format = PIPE_FORMAT_S8_USCALED_Z24_UNORM;
+       fdesc.format = PIPE_FORMAT_S8_UINT_Z24_UNORM;
        break;
     case xa_format_yuv8:
        fdesc.format = PIPE_FORMAT_L8_UNORM;
index 3350ac736cfecaafdd22e619127ef90cef8a167e..e81f7b81ca12f78c67f29cbc7722f7aba3b12299 100644 (file)
@@ -124,7 +124,7 @@ dri2_do_create_buffer(DrawablePtr pDraw, DRI2BufferPtr buffer, unsigned int form
                }
             } else {
                template.format = ms->ds_depth_bits_last ?
-                                 PIPE_FORMAT_Z24_UNORM_S8_USCALED : PIPE_FORMAT_S8_USCALED_Z24_UNORM;
+                                 PIPE_FORMAT_Z24_UNORM_S8_UINT : PIPE_FORMAT_S8_UINT_Z24_UNORM;
             }
            template.width0 = pDraw->width;
            template.height0 = pDraw->height;
@@ -456,7 +456,7 @@ xorg_dri2_init(ScreenPtr pScreen)
                                         0,
                                          PIPE_BIND_DEPTH_STENCIL);
     ms->ds_depth_bits_last =
-        ms->screen->is_format_supported(ms->screen, PIPE_FORMAT_Z24_UNORM_S8_USCALED,
+        ms->screen->is_format_supported(ms->screen, PIPE_FORMAT_Z24_UNORM_S8_UINT,
                                         PIPE_TEXTURE_2D,
                                         0,
                                          PIPE_BIND_DEPTH_STENCIL);
index f831e5dd754817afcf396f3e7aa01c672cbf009d..b0e44766bd90dae85383fbf4385eccc60109345b 100644 (file)
@@ -180,10 +180,10 @@ print_unpacked_z_32unorm(const struct util_format_description *format_desc,
 
 
 static void
-print_unpacked_s_8uscaled(const struct util_format_description *format_desc,
-                          const char *prefix,
-                          uint8_t unpacked[UTIL_FORMAT_MAX_UNPACKED_HEIGHT][UTIL_FORMAT_MAX_UNPACKED_WIDTH],
-                          const char *suffix)
+print_unpacked_s_8uint(const struct util_format_description *format_desc,
+                       const char *prefix,
+                       uint8_t unpacked[UTIL_FORMAT_MAX_UNPACKED_HEIGHT][UTIL_FORMAT_MAX_UNPACKED_WIDTH],
+                       const char *suffix)
 {
    unsigned i, j;
    const char *sep = "";
@@ -553,7 +553,7 @@ test_format_pack_z_32unorm(const struct util_format_description *format_desc,
 
 
 static boolean
-test_format_unpack_s_8uscaled(const struct util_format_description *format_desc,
+test_format_unpack_s_8uint(const struct util_format_description *format_desc,
                                const struct util_format_test_case *test)
 {
    uint8_t unpacked[UTIL_FORMAT_MAX_UNPACKED_HEIGHT][UTIL_FORMAT_MAX_UNPACKED_WIDTH] = { { 0 } };
@@ -561,7 +561,7 @@ test_format_unpack_s_8uscaled(const struct util_format_description *format_desc,
    unsigned i, j;
    boolean success;
 
-   format_desc->unpack_s_8uscaled(&unpacked[0][0], sizeof unpacked[0],
+   format_desc->unpack_s_8uint(&unpacked[0][0], sizeof unpacked[0],
                                   test->packed, 0,
                                   format_desc->block.width, format_desc->block.height);
 
@@ -581,8 +581,8 @@ test_format_unpack_s_8uscaled(const struct util_format_description *format_desc,
    }
 
    if (!success) {
-      print_unpacked_s_8uscaled(format_desc, "FAILED: ", unpacked, " obtained\n");
-      print_unpacked_s_8uscaled(format_desc, "        ", expected, " expected\n");
+      print_unpacked_s_8uint(format_desc, "FAILED: ", unpacked, " obtained\n");
+      print_unpacked_s_8uint(format_desc, "        ", expected, " expected\n");
    }
 
    return success;
@@ -590,7 +590,7 @@ test_format_unpack_s_8uscaled(const struct util_format_description *format_desc,
 
 
 static boolean
-test_format_pack_s_8uscaled(const struct util_format_description *format_desc,
+test_format_pack_s_8uint(const struct util_format_description *format_desc,
                              const struct util_format_test_case *test)
 {
    uint8_t unpacked[UTIL_FORMAT_MAX_UNPACKED_HEIGHT][UTIL_FORMAT_MAX_UNPACKED_WIDTH];
@@ -609,7 +609,7 @@ test_format_pack_s_8uscaled(const struct util_format_description *format_desc,
 
    memset(packed, 0, sizeof packed);
 
-   format_desc->pack_s_8uscaled(packed, 0,
+   format_desc->pack_s_8uint(packed, 0,
                                 &unpacked[0][0], sizeof unpacked[0],
                                 format_desc->block.width, format_desc->block.height);
 
@@ -694,8 +694,8 @@ test_all(void)
       TEST_ONE_FUNC(pack_z_32unorm);
       TEST_ONE_FUNC(unpack_z_float);
       TEST_ONE_FUNC(pack_z_float);
-      TEST_ONE_FUNC(unpack_s_8uscaled);
-      TEST_ONE_FUNC(pack_s_8uscaled);
+      TEST_ONE_FUNC(unpack_s_8uint);
+      TEST_ONE_FUNC(pack_s_8uint);
 
 #     undef TEST_ONE_FUNC
    }
index 74e87f0e446802b7570670765c28665885f8fc46..89e0a73f1c99c87ac9a6bf62bd9e122f2ffb1036 100644 (file)
@@ -871,7 +871,7 @@ draw_stencil_pixels(struct gl_context *ctx, GLint x, GLint y,
 
          if (format == GL_DEPTH_STENCIL) {
             GLenum ztype =
-               pt->resource->format == PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED ?
+               pt->resource->format == PIPE_FORMAT_Z32_FLOAT_S8X24_UINT ?
                GL_FLOAT : GL_UNSIGNED_INT;
 
             _mesa_unpack_depth_span(ctx, spanWidth, ztype, zValues,
@@ -896,14 +896,14 @@ draw_stencil_pixels(struct gl_context *ctx, GLint x, GLint y,
 
             /* now pack the stencil (and Z) values in the dest format */
             switch (pt->resource->format) {
-            case PIPE_FORMAT_S8_USCALED:
+            case PIPE_FORMAT_S8_UINT:
                {
                   ubyte *dest = stmap + spanY * pt->stride + spanX;
                   assert(usage == PIPE_TRANSFER_WRITE);
                   memcpy(dest, sValues, spanWidth);
                }
                break;
-            case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+            case PIPE_FORMAT_Z24_UNORM_S8_UINT:
                if (format == GL_DEPTH_STENCIL) {
                   uint *dest = (uint *) (stmap + spanY * pt->stride + spanX*4);
                   GLint k;
@@ -921,7 +921,7 @@ draw_stencil_pixels(struct gl_context *ctx, GLint x, GLint y,
                   }
                }
                break;
-            case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+            case PIPE_FORMAT_S8_UINT_Z24_UNORM:
                if (format == GL_DEPTH_STENCIL) {
                   uint *dest = (uint *) (stmap + spanY * pt->stride + spanX*4);
                   GLint k;
@@ -939,7 +939,7 @@ draw_stencil_pixels(struct gl_context *ctx, GLint x, GLint y,
                   }
                }
                break;
-            case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+            case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
                if (format == GL_DEPTH_STENCIL) {
                   uint *dest = (uint *) (stmap + spanY * pt->stride + spanX*4);
                   GLfloat *destf = (GLfloat*)dest;
@@ -1112,20 +1112,20 @@ st_DrawPixels(struct gl_context *ctx, GLint x, GLint y,
                enum pipe_format stencil_format = PIPE_FORMAT_NONE;
 
                switch (pt->format) {
-               case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
-               case PIPE_FORMAT_X24S8_USCALED:
-                  stencil_format = PIPE_FORMAT_X24S8_USCALED;
+               case PIPE_FORMAT_Z24_UNORM_S8_UINT:
+               case PIPE_FORMAT_X24S8_UINT:
+                  stencil_format = PIPE_FORMAT_X24S8_UINT;
                   break;
-               case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
-               case PIPE_FORMAT_S8X24_USCALED:
-                  stencil_format = PIPE_FORMAT_S8X24_USCALED;
+               case PIPE_FORMAT_S8_UINT_Z24_UNORM:
+               case PIPE_FORMAT_S8X24_UINT:
+                  stencil_format = PIPE_FORMAT_S8X24_UINT;
                   break;
-               case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
-               case PIPE_FORMAT_X32_S8X24_USCALED:
-                  stencil_format = PIPE_FORMAT_X32_S8X24_USCALED;
+               case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
+               case PIPE_FORMAT_X32_S8X24_UINT:
+                  stencil_format = PIPE_FORMAT_X32_S8X24_UINT;
                   break;
-               case PIPE_FORMAT_S8_USCALED:
-                  stencil_format = PIPE_FORMAT_S8_USCALED;
+               case PIPE_FORMAT_S8_UINT:
+                  stencil_format = PIPE_FORMAT_S8_UINT;
                   break;
                default:
                   assert(0);
@@ -1241,7 +1241,7 @@ copy_stencil_pixels(struct gl_context *ctx, GLint srcx, GLint srcy,
       src = buffer + i * width;
 
       switch (ptDraw->resource->format) {
-      case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+      case PIPE_FORMAT_Z24_UNORM_S8_UINT:
          {
             uint *dst4 = (uint *) dst;
             int j;
@@ -1252,7 +1252,7 @@ copy_stencil_pixels(struct gl_context *ctx, GLint srcx, GLint srcy,
             }
          }
          break;
-      case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+      case PIPE_FORMAT_S8_UINT_Z24_UNORM:
          {
             uint *dst4 = (uint *) dst;
             int j;
@@ -1263,11 +1263,11 @@ copy_stencil_pixels(struct gl_context *ctx, GLint srcx, GLint srcy,
             }
          }
          break;
-      case PIPE_FORMAT_S8_USCALED:
+      case PIPE_FORMAT_S8_UINT:
          assert(usage == PIPE_TRANSFER_WRITE);
          memcpy(dst, src, width);
          break;
-      case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+      case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
          {
             uint *dst4 = (uint *) dst;
             int j;
index 531296fb302d4a9c144e79f2f53d5fcd054693f7..37c20ebe30faab99e077a88966d18effd7cd77c6 100644 (file)
@@ -53,7 +53,7 @@ st_pipe_format_to_base_format(enum pipe_format format)
          base_format = GL_DEPTH_STENCIL;
       }
       else {
-         if (format == PIPE_FORMAT_S8_USCALED)
+         if (format == PIPE_FORMAT_S8_UINT)
             base_format = GL_STENCIL_INDEX;
          else
             base_format = GL_DEPTH_COMPONENT;
index 4d321587fc87add3d5f99a29911f7cf82714a594..6da65d7b9eddf69ed3c6c6c4d4c8daabe731a912 100644 (file)
@@ -259,13 +259,13 @@ st_new_renderbuffer_fb(enum pipe_format format, int samples, boolean sw)
    case PIPE_FORMAT_Z32_UNORM:
       strb->Base.InternalFormat = GL_DEPTH_COMPONENT32;
       break;
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
    case PIPE_FORMAT_Z24X8_UNORM:
    case PIPE_FORMAT_X8Z24_UNORM:
       strb->Base.InternalFormat = GL_DEPTH24_STENCIL8_EXT;
       break;
-   case PIPE_FORMAT_S8_USCALED:
+   case PIPE_FORMAT_S8_UINT:
       strb->Base.InternalFormat = GL_STENCIL_INDEX8_EXT;
       break;
    case PIPE_FORMAT_R16G16B16A16_SNORM:
index 7fa1672fda8948fe0d5d450e6d5a538e9c8cf8bf..bd73f3bf0370083963fd87a8077260797c980721 100644 (file)
@@ -109,13 +109,13 @@ st_read_stencil_pixels(struct gl_context *ctx, GLint x, GLint y,
 
       /* get stencil (and Z) values */
       switch (pt->resource->format) {
-      case PIPE_FORMAT_S8_USCALED:
+      case PIPE_FORMAT_S8_UINT:
          {
             const ubyte *src = stmap + srcY * pt->stride;
             memcpy(sValues, src, width);
          }
          break;
-      case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+      case PIPE_FORMAT_Z24_UNORM_S8_UINT:
          if (format == GL_DEPTH_STENCIL) {
             const uint *src = (uint *) (stmap + srcY * pt->stride);
             const GLfloat scale = 1.0f / (0xffffff);
@@ -133,7 +133,7 @@ st_read_stencil_pixels(struct gl_context *ctx, GLint x, GLint y,
             }
          }
          break;
-      case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+      case PIPE_FORMAT_S8_UINT_Z24_UNORM:
          if (format == GL_DEPTH_STENCIL) {
             const uint *src = (uint *) (stmap + srcY * pt->stride);
             const GLfloat scale = 1.0f / (0xffffff);
@@ -151,7 +151,7 @@ st_read_stencil_pixels(struct gl_context *ctx, GLint x, GLint y,
             }
          }
          break;
-      case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+      case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
          if (format == GL_DEPTH_STENCIL) {
             const uint *src = (uint *) (stmap + srcY * pt->stride);
             const GLfloat *srcf = (const GLfloat*)src;
@@ -502,7 +502,7 @@ st_readpixels(struct gl_context *ctx, GLint x, GLint y, GLsizei width, GLsizei h
       const GLint dstStride = _mesa_image_row_stride(&clippedPacking, width,
                                                      format, type);
 
-      if (pformat == PIPE_FORMAT_Z24_UNORM_S8_USCALED ||
+      if (pformat == PIPE_FORMAT_Z24_UNORM_S8_UINT ||
           pformat == PIPE_FORMAT_Z24X8_UNORM) {
          if (format == GL_DEPTH_COMPONENT) {
             for (i = 0; i < height; i++) {
@@ -534,7 +534,7 @@ st_readpixels(struct gl_context *ctx, GLint x, GLint y, GLsizei width, GLsizei h
             }
          }
       }
-      else if (pformat == PIPE_FORMAT_S8_USCALED_Z24_UNORM ||
+      else if (pformat == PIPE_FORMAT_S8_UINT_Z24_UNORM ||
                pformat == PIPE_FORMAT_X8Z24_UNORM) {
          if (format == GL_DEPTH_COMPONENT) {
             for (i = 0; i < height; i++) {
@@ -601,7 +601,7 @@ st_readpixels(struct gl_context *ctx, GLint x, GLint y, GLsizei width, GLsizei h
             dst += dstStride;
          }
       }
-      else if (pformat == PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED) {
+      else if (pformat == PIPE_FORMAT_Z32_FLOAT_S8X24_UINT) {
          assert(format == GL_DEPTH_COMPONENT);
          for (i = 0; i < height; i++) {
             GLfloat zfloat[MAX_WIDTH];    /* Z32 */
index 6707fcae122ec3259846c2a4b31afa89d7d753c1..a1f029089d0e84b6373a8a6de8ed1ac02b7f7b30 100644 (file)
@@ -368,18 +368,18 @@ void st_init_extensions(struct st_context *st)
    /* GL_EXT_packed_depth_stencil requires both the ability to render to
     * a depth/stencil buffer and texture from depth/stencil source.
     */
-   if (screen->is_format_supported(screen, PIPE_FORMAT_S8_USCALED_Z24_UNORM,
+   if (screen->is_format_supported(screen, PIPE_FORMAT_S8_UINT_Z24_UNORM,
                                    PIPE_TEXTURE_2D, 0,
                                    PIPE_BIND_DEPTH_STENCIL) &&
-       screen->is_format_supported(screen, PIPE_FORMAT_S8_USCALED_Z24_UNORM,
+       screen->is_format_supported(screen, PIPE_FORMAT_S8_UINT_Z24_UNORM,
                                    PIPE_TEXTURE_2D, 0,
                                    PIPE_BIND_SAMPLER_VIEW)) {
       ctx->Extensions.EXT_packed_depth_stencil = GL_TRUE;
    }
-   else if (screen->is_format_supported(screen, PIPE_FORMAT_Z24_UNORM_S8_USCALED,
+   else if (screen->is_format_supported(screen, PIPE_FORMAT_Z24_UNORM_S8_UINT,
                                         PIPE_TEXTURE_2D, 0,
                                         PIPE_BIND_DEPTH_STENCIL) &&
-            screen->is_format_supported(screen, PIPE_FORMAT_Z24_UNORM_S8_USCALED,
+            screen->is_format_supported(screen, PIPE_FORMAT_Z24_UNORM_S8_UINT,
                                         PIPE_TEXTURE_2D, 0,
                                         PIPE_BIND_SAMPLER_VIEW)) {
       ctx->Extensions.EXT_packed_depth_stencil = GL_TRUE;
@@ -650,7 +650,7 @@ void st_init_extensions(struct st_context *st)
                                    PIPE_TEXTURE_2D, 0,
                                    PIPE_BIND_DEPTH_STENCIL |
                                    PIPE_BIND_SAMPLER_VIEW) &&
-       screen->is_format_supported(screen, PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED,
+       screen->is_format_supported(screen, PIPE_FORMAT_Z32_FLOAT_S8X24_UINT,
                                    PIPE_TEXTURE_2D, 0,
                                    PIPE_BIND_DEPTH_STENCIL |
                                    PIPE_BIND_SAMPLER_VIEW)) {
index 6e8ab94f412e22c5ba9983a17c0f94c30cee6fd1..196433d5e23357eaca274bd4ef2e617638ce75f7 100644 (file)
@@ -89,13 +89,13 @@ st_format_datatype(enum pipe_format format)
                format == PIPE_FORMAT_R9G9B9E5_FLOAT) {
          return GL_FLOAT;
       }
-      else if (format == PIPE_FORMAT_Z24_UNORM_S8_USCALED ||
-               format == PIPE_FORMAT_S8_USCALED_Z24_UNORM ||
+      else if (format == PIPE_FORMAT_Z24_UNORM_S8_UINT ||
+               format == PIPE_FORMAT_S8_UINT_Z24_UNORM ||
                format == PIPE_FORMAT_Z24X8_UNORM ||
                format == PIPE_FORMAT_X8Z24_UNORM) {
          return GL_UNSIGNED_INT_24_8;
       }
-      else if (format == PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED) {
+      else if (format == PIPE_FORMAT_Z32_FLOAT_S8X24_UINT) {
          return GL_FLOAT_32_UNSIGNED_INT_24_8_REV;
       }
       else {
@@ -199,19 +199,19 @@ st_mesa_format_to_pipe_format(gl_format mesaFormat)
    case MESA_FORMAT_Z32:
       return PIPE_FORMAT_Z32_UNORM;
    case MESA_FORMAT_Z24_S8:
-      return PIPE_FORMAT_S8_USCALED_Z24_UNORM;
+      return PIPE_FORMAT_S8_UINT_Z24_UNORM;
    case MESA_FORMAT_S8_Z24:
-      return PIPE_FORMAT_Z24_UNORM_S8_USCALED;
+      return PIPE_FORMAT_Z24_UNORM_S8_UINT;
    case MESA_FORMAT_Z24_X8:
       return PIPE_FORMAT_X8Z24_UNORM;
    case MESA_FORMAT_X8_Z24:
       return PIPE_FORMAT_Z24X8_UNORM;
    case MESA_FORMAT_S8:
-      return PIPE_FORMAT_S8_USCALED;
+      return PIPE_FORMAT_S8_UINT;
    case MESA_FORMAT_Z32_FLOAT:
       return PIPE_FORMAT_Z32_FLOAT;
    case MESA_FORMAT_Z32_FLOAT_X24S8:
-      return PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED;
+      return PIPE_FORMAT_Z32_FLOAT_S8X24_UINT;
    case MESA_FORMAT_YCBCR:
       return PIPE_FORMAT_UYVY;
 #if FEATURE_texture_s3tc
@@ -508,7 +508,7 @@ st_pipe_format_to_mesa_format(enum pipe_format format)
       return MESA_FORMAT_I8;
    case PIPE_FORMAT_I16_UNORM:
       return MESA_FORMAT_I16;
-   case PIPE_FORMAT_S8_USCALED:
+   case PIPE_FORMAT_S8_UINT:
       return MESA_FORMAT_S8;
 
    case PIPE_FORMAT_R16G16B16A16_UNORM:
@@ -518,17 +518,17 @@ st_pipe_format_to_mesa_format(enum pipe_format format)
       return MESA_FORMAT_Z16;
    case PIPE_FORMAT_Z32_UNORM:
       return MESA_FORMAT_Z32;
-   case PIPE_FORMAT_S8_USCALED_Z24_UNORM:
+   case PIPE_FORMAT_S8_UINT_Z24_UNORM:
       return MESA_FORMAT_Z24_S8;
    case PIPE_FORMAT_X8Z24_UNORM:
       return MESA_FORMAT_Z24_X8;
    case PIPE_FORMAT_Z24X8_UNORM:
       return MESA_FORMAT_X8_Z24;
-   case PIPE_FORMAT_Z24_UNORM_S8_USCALED:
+   case PIPE_FORMAT_Z24_UNORM_S8_UINT:
       return MESA_FORMAT_S8_Z24;
    case PIPE_FORMAT_Z32_FLOAT:
       return MESA_FORMAT_Z32_FLOAT;
-   case PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED:
+   case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT:
       return MESA_FORMAT_Z32_FLOAT_X24S8;
 
    case PIPE_FORMAT_UYVY:
@@ -818,8 +818,8 @@ struct format_mapping
       PIPE_FORMAT_Z24X8_UNORM, \
       PIPE_FORMAT_X8Z24_UNORM, \
       PIPE_FORMAT_Z16_UNORM, \
-      PIPE_FORMAT_Z24_UNORM_S8_USCALED, \
-      PIPE_FORMAT_S8_USCALED_Z24_UNORM, \
+      PIPE_FORMAT_Z24_UNORM_S8_UINT, \
+      PIPE_FORMAT_S8_UINT_Z24_UNORM, \
       0
 
 /**
@@ -988,19 +988,19 @@ static const struct format_mapping format_map[] = {
       { GL_STENCIL_INDEX, GL_STENCIL_INDEX1_EXT, GL_STENCIL_INDEX4_EXT,
         GL_STENCIL_INDEX8_EXT, GL_STENCIL_INDEX16_EXT, 0 },
       {
-         PIPE_FORMAT_S8_USCALED, PIPE_FORMAT_Z24_UNORM_S8_USCALED,
-         PIPE_FORMAT_S8_USCALED_Z24_UNORM, 0
+         PIPE_FORMAT_S8_UINT, PIPE_FORMAT_Z24_UNORM_S8_UINT,
+         PIPE_FORMAT_S8_UINT_Z24_UNORM, 0
       }
    },
 
    /* Depth / Stencil formats */
    {
       { GL_DEPTH_STENCIL_EXT, GL_DEPTH24_STENCIL8_EXT, 0 },
-      { PIPE_FORMAT_Z24_UNORM_S8_USCALED, PIPE_FORMAT_S8_USCALED_Z24_UNORM, 0 }
+      { PIPE_FORMAT_Z24_UNORM_S8_UINT, PIPE_FORMAT_S8_UINT_Z24_UNORM, 0 }
    },
    {
       { GL_DEPTH32F_STENCIL8, 0 },
-      { PIPE_FORMAT_Z32_FLOAT_S8X24_USCALED, 0 }
+      { PIPE_FORMAT_Z32_FLOAT_S8X24_UINT, 0 }
    },
 
    /* sRGB formats */