mesa: start adding GL 3.1 signed normalized texture formats
authorBrian Paul <brianp@vmware.com>
Tue, 27 Apr 2010 02:35:19 +0000 (20:35 -0600)
committerBrian Paul <brianp@vmware.com>
Tue, 27 Apr 2010 02:35:19 +0000 (20:35 -0600)
src/mesa/main/formats.c
src/mesa/main/formats.h
src/mesa/main/texfetch.c
src/mesa/main/texfetch_tmp.h
src/mesa/main/texformat.c
src/mesa/main/texstore.c

index d0c9c0028b2cea90d3bc0bedbe2410523f092c1d..b9796e4a4236bc26ac44d6bdd03379dcc631d49d 100644 (file)
@@ -637,6 +637,35 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] =
       0, 0, 0, 0, 0,
       1, 1, 2
    },
+
+   /* Signed 8 bits / channel */
+   {
+      MESA_FORMAT_SIGNED_R8,        /* Name */
+      "MESA_FORMAT_SIGNED_R8",      /* StrName */
+      GL_RGBA,                      /* BaseFormat */
+      GL_SIGNED_NORMALIZED,         /* DataType */
+      8, 0, 0, 0,                   /* Red/Green/Blue/AlphaBits */
+      0, 0, 0, 0, 0,                /* Lum/Int/Index/Depth/StencilBits */
+      1, 1, 1                       /* BlockWidth/Height,Bytes */
+   },
+   {
+      MESA_FORMAT_SIGNED_RG88,
+      "MESA_FORMAT_SIGNED_RG88",
+      GL_RGBA,
+      GL_SIGNED_NORMALIZED,
+      8, 8, 0, 0,
+      0, 0, 0, 0, 0,
+      1, 1, 2
+   },
+   {
+      MESA_FORMAT_SIGNED_RGBX8888,
+      "MESA_FORMAT_SIGNED_RGBX8888",
+      GL_RGBA,
+      GL_SIGNED_NORMALIZED,
+      8, 8, 8, 0,
+      0, 0, 0, 0, 0,
+      1, 1, 4                       /* 4 bpp, but no alpha */
+   },
    {
       MESA_FORMAT_SIGNED_RGBA8888,
       "MESA_FORMAT_SIGNED_RGBA8888",
@@ -655,6 +684,35 @@ static struct gl_format_info format_info[MESA_FORMAT_COUNT] =
       0, 0, 0, 0, 0,
       1, 1, 4
    },
+
+   /* Signed 16 bits / channel */
+   {
+      MESA_FORMAT_SIGNED_R_16,
+      "MESA_FORMAT_SIGNED_R_16",
+      GL_RGBA,
+      GL_SIGNED_NORMALIZED,
+      16, 0, 0, 0,
+      0, 0, 0, 0, 0,
+      1, 1, 2
+   },
+   {
+      MESA_FORMAT_SIGNED_RG_16,
+      "MESA_FORMAT_SIGNED_RG_16",
+      GL_RGBA,
+      GL_SIGNED_NORMALIZED,
+      16, 16, 0, 0,
+      0, 0, 0, 0, 0,
+      1, 1, 4
+   },
+   {
+      MESA_FORMAT_SIGNED_RGB_16,
+      "MESA_FORMAT_SIGNED_RGB_16",
+      GL_RGBA,
+      GL_SIGNED_NORMALIZED,
+      16, 16, 16, 0,
+      0, 0, 0, 0, 0,
+      1, 1, 6
+   },
    {
       MESA_FORMAT_SIGNED_RGBA_16,
       "MESA_FORMAT_SIGNED_RGBA_16",
index 0eeeb8b2bacf3ba59da82d761230ac09e7381056..97e1fc5df465a070752ff488a3a44474f49f13cb 100644 (file)
@@ -130,13 +130,21 @@ typedef enum
    MESA_FORMAT_INTENSITY_FLOAT16,
    /*@}*/
 
+                                  /* msb <------ TEXEL BITS -----------> lsb */
+                                  /* ---- ---- ---- ---- ---- ---- ---- ---- */
    /**
     * \name Signed fixed point texture formats.
     */
    /*@{*/
-   MESA_FORMAT_DUDV8,
-   MESA_FORMAT_SIGNED_RGBA8888,
-   MESA_FORMAT_SIGNED_RGBA8888_REV,
+   MESA_FORMAT_DUDV8,             /*                     DUDU DUDU DVDV DVDV */
+   MESA_FORMAT_SIGNED_R8,         /*                               RRRR RRRR */
+   MESA_FORMAT_SIGNED_RG88,       /*                     RRRR RRRR GGGG GGGG */
+   MESA_FORMAT_SIGNED_RGBX8888,   /* RRRR RRRR GGGG GGGG BBBB BBBB xxxx xxxx */
+   MESA_FORMAT_SIGNED_RGBA8888,   /* RRRR RRRR GGGG GGGG BBBB BBBB AAAA AAAA */
+   MESA_FORMAT_SIGNED_RGBA8888_REV,/*AAAA AAAA BBBB BBBB GGGG GGGG RRRR RRRR */
+   MESA_FORMAT_SIGNED_R_16,
+   MESA_FORMAT_SIGNED_RG_16,
+   MESA_FORMAT_SIGNED_RGB_16,
    MESA_FORMAT_SIGNED_RGBA_16,
    /*@}*/
 
index 323850e19812ee508842412729a976aec8c2a4c8..48a22c194552d7d17446f0af56423e1d9d6a4b3e 100644 (file)
@@ -559,6 +559,27 @@ texfetch_funcs[MESA_FORMAT_COUNT] =
       fetch_texel_3d_dudv8,
       NULL
    },
+   {
+      MESA_FORMAT_SIGNED_R8,
+      fetch_texel_1d_signed_r8,
+      fetch_texel_2d_signed_r8,
+      fetch_texel_3d_signed_r8,
+      store_texel_signed_r8
+   },
+   {
+      MESA_FORMAT_SIGNED_RG88,
+      fetch_texel_1d_signed_rg88,
+      fetch_texel_2d_signed_rg88,
+      fetch_texel_3d_signed_rg88,
+      store_texel_signed_rg88
+   },
+   {
+      MESA_FORMAT_SIGNED_RGBX8888,
+      fetch_texel_1d_signed_rgbx8888,
+      fetch_texel_2d_signed_rgbx8888,
+      fetch_texel_3d_signed_rgbx8888,
+      store_texel_signed_rgbx8888
+   },
    {
       MESA_FORMAT_SIGNED_RGBA8888,
       fetch_texel_1d_signed_rgba8888,
@@ -573,12 +594,33 @@ texfetch_funcs[MESA_FORMAT_COUNT] =
       fetch_texel_3d_signed_rgba8888_rev,
       store_texel_signed_rgba8888_rev
    },
+   {
+      MESA_FORMAT_SIGNED_R_16,
+      fetch_texel_1d_signed_r_16,
+      fetch_texel_2d_signed_r_16,
+      fetch_texel_3d_signed_r_16,
+      store_texel_signed_r_16
+   },
+   {
+      MESA_FORMAT_SIGNED_RG_16,
+      fetch_texel_1d_signed_rg_16,
+      fetch_texel_2d_signed_rg_16,
+      fetch_texel_3d_signed_rg_16,
+      store_texel_signed_rg_16
+   },
+   {
+      MESA_FORMAT_SIGNED_RGB_16,
+      fetch_texel_1d_signed_rgb_16,
+      fetch_texel_2d_signed_rgb_16,
+      fetch_texel_3d_signed_rgb_16,
+      store_texel_signed_rgb_16
+   },
    {
       MESA_FORMAT_SIGNED_RGBA_16,
-      NULL, /* XXX to do */
-      NULL,
-      NULL,
-      NULL
+      fetch_texel_1d_signed_rgba_16,
+      fetch_texel_2d_signed_rgba_16,
+      fetch_texel_3d_signed_rgba_16,
+      store_texel_signed_rgba_16
    },
 };
 
index b11ed5c39a347fb7d4a9d07cc73b34b4c9f82fb9..4df2b19181a458a780504d4a4b13f77d439ef107 100644 (file)
@@ -1209,6 +1209,76 @@ static void FETCH(dudv8)(const struct gl_texture_image *texImage,
    texel[ACOMP] = 0;
 }
 
+
+/* MESA_FORMAT_SIGNED_R8 ***********************************************/
+
+static void FETCH(signed_r8)( const struct gl_texture_image *texImage,
+                              GLint i, GLint j, GLint k, GLfloat *texel )
+{
+   const GLbyte s = *TEXEL_ADDR(GLbyte, texImage, i, j, k, 1);
+   texel[RCOMP] = BYTE_TO_FLOAT_TEX( s );
+   texel[GCOMP] = 0.0F;
+   texel[BCOMP] = 0.0F;
+   texel[ACOMP] = 1.0F;
+}
+
+#if DIM == 3
+static void store_texel_signed_r8(struct gl_texture_image *texImage,
+                                  GLint i, GLint j, GLint k, const void *texel)
+{
+   const GLbyte *rgba = (const GLbyte *) texel;
+   GLbyte *dst = TEXEL_ADDR(GLbyte, texImage, i, j, k, 1);
+   *dst = rgba[RCOMP];
+}
+#endif
+
+
+/* MESA_FORMAT_SIGNED_RG88 ***********************************************/
+
+static void FETCH(signed_rg88)( const struct gl_texture_image *texImage,
+                                GLint i, GLint j, GLint k, GLfloat *texel )
+{
+   const GLushort s = *TEXEL_ADDR(GLshort, texImage, i, j, k, 1);
+   texel[RCOMP] = BYTE_TO_FLOAT_TEX( (GLbyte) (s >> 8) );
+   texel[GCOMP] = BYTE_TO_FLOAT_TEX( (GLbyte) (s & 0xff) );
+   texel[BCOMP] = 0.0F;
+   texel[ACOMP] = 1.0F;
+}
+
+#if DIM == 3
+static void store_texel_signed_rg88(struct gl_texture_image *texImage,
+                                    GLint i, GLint j, GLint k, const void *texel)
+{
+   const GLbyte *rg = (const GLbyte *) texel;
+   GLushort *dst = TEXEL_ADDR(GLushort, texImage, i, j, k, 2);
+   *dst = PACK_COLOR_88(rg[RCOMP], rg[GCOMP]);
+}
+#endif
+
+
+/* MESA_FORMAT_SIGNED_RGBX8888 ***********************************************/
+
+static void FETCH(signed_rgbx8888)( const struct gl_texture_image *texImage,
+                                   GLint i, GLint j, GLint k, GLfloat *texel )
+{
+   const GLuint s = *TEXEL_ADDR(GLuint, texImage, i, j, k, 1);
+   texel[RCOMP] = BYTE_TO_FLOAT_TEX( (GLbyte) (s >> 24) );
+   texel[GCOMP] = BYTE_TO_FLOAT_TEX( (GLbyte) (s >> 16) );
+   texel[BCOMP] = BYTE_TO_FLOAT_TEX( (GLbyte) (s >>  8) );
+   texel[ACOMP] = 1.0f;
+}
+
+#if DIM == 3
+static void store_texel_signed_rgbx8888(struct gl_texture_image *texImage,
+                                        GLint i, GLint j, GLint k, const void *texel)
+{
+   const GLbyte *rgba = (const GLbyte *) texel;
+   GLuint *dst = TEXEL_ADDR(GLuint, texImage, i, j, k, 1);
+   *dst = PACK_COLOR_8888(rgba[RCOMP], rgba[GCOMP], rgba[BCOMP], 255);
+}
+#endif
+
+
 /* MESA_FORMAT_SIGNED_RGBA8888 ***********************************************/
 
 static void FETCH(signed_rgba8888)( const struct gl_texture_image *texImage,
@@ -1253,6 +1323,113 @@ static void store_texel_signed_rgba8888_rev(struct gl_texture_image *texImage,
 
 
 
+/* MESA_FORMAT_SIGNED_R_16 ***********************************************/
+
+static void
+FETCH(signed_r_16)(const struct gl_texture_image *texImage,
+                   GLint i, GLint j, GLint k, GLfloat *texel)
+{
+   const GLshort s = *TEXEL_ADDR(GLshort, texImage, i, j, k, 1);
+   texel[RCOMP] = SHORT_TO_FLOAT_TEX( s );
+   texel[GCOMP] = 0.0F;
+   texel[BCOMP] = 0.0F;
+   texel[ACOMP] = 1.0F;
+}
+
+#if DIM == 3
+static void
+store_texel_signed_r_16(struct gl_texture_image *texImage,
+                        GLint i, GLint j, GLint k, const void *texel)
+{
+   const GLshort *rgba = (const GLshort *) texel;
+   GLshort *dst = TEXEL_ADDR(GLshort, texImage, i, j, k, 1);
+   *dst = rgba[0];
+}
+#endif
+
+
+/* MESA_FORMAT_SIGNED_RG_16 ***********************************************/
+
+static void
+FETCH(signed_rg_16)(const struct gl_texture_image *texImage,
+                    GLint i, GLint j, GLint k, GLfloat *texel)
+{
+   const GLshort *s = TEXEL_ADDR(GLshort, texImage, i, j, k, 2);
+   texel[RCOMP] = SHORT_TO_FLOAT_TEX( s[0] );
+   texel[GCOMP] = SHORT_TO_FLOAT_TEX( s[1] );
+   texel[BCOMP] = 0.0F;
+   texel[ACOMP] = 1.0F;
+}
+
+#if DIM == 3
+static void
+store_texel_signed_rg_16(struct gl_texture_image *texImage,
+                         GLint i, GLint j, GLint k, const void *texel)
+{
+   const GLshort *rgba = (const GLshort *) texel;
+   GLshort *dst = TEXEL_ADDR(GLshort, texImage, i, j, k, 2);
+   dst[0] = rgba[RCOMP];
+   dst[1] = rgba[GCOMP];
+}
+#endif
+
+
+/* MESA_FORMAT_SIGNED_RGB_16 ***********************************************/
+
+static void 
+FETCH(signed_rgb_16)(const struct gl_texture_image *texImage,
+                     GLint i, GLint j, GLint k, GLfloat *texel)
+{
+   const GLshort *s = TEXEL_ADDR(GLshort, texImage, i, j, k, 3);
+   texel[RCOMP] = SHORT_TO_FLOAT_TEX( s[0] );
+   texel[GCOMP] = SHORT_TO_FLOAT_TEX( s[1] );
+   texel[BCOMP] = SHORT_TO_FLOAT_TEX( s[3] );
+   texel[ACOMP] = 1.0F;
+}
+
+#if DIM == 3
+static void
+store_texel_signed_rgb_16(struct gl_texture_image *texImage,
+                          GLint i, GLint j, GLint k, const void *texel)
+{
+   const GLshort *rgba = (const GLshort *) texel;
+   GLshort *dst = TEXEL_ADDR(GLshort, texImage, i, j, k, 3);
+   dst[0] = rgba[RCOMP];
+   dst[1] = rgba[GCOMP];
+   dst[2] = rgba[BCOMP];
+}
+#endif
+
+
+/* MESA_FORMAT_SIGNED_RGB_16 ***********************************************/
+
+static void
+FETCH(signed_rgba_16)(const struct gl_texture_image *texImage,
+                      GLint i, GLint j, GLint k, GLfloat *texel)
+{
+   const GLshort *s = TEXEL_ADDR(GLshort, texImage, i, j, k, 4);
+   texel[RCOMP] = SHORT_TO_FLOAT_TEX( s[0] );
+   texel[GCOMP] = SHORT_TO_FLOAT_TEX( s[1] );
+   texel[BCOMP] = SHORT_TO_FLOAT_TEX( s[3] );
+   texel[ACOMP] = SHORT_TO_FLOAT_TEX( s[4] );
+}
+
+#if DIM == 3
+static void
+store_texel_signed_rgba_16(struct gl_texture_image *texImage,
+                           GLint i, GLint j, GLint k, const void *texel)
+{
+   const GLshort *rgba = (const GLshort *) texel;
+   GLshort *dst = TEXEL_ADDR(GLshort, texImage, i, j, k, 4);
+   dst[0] = rgba[RCOMP];
+   dst[1] = rgba[GCOMP];
+   dst[2] = rgba[BCOMP];
+   dst[3] = rgba[ACOMP];
+}
+#endif
+
+
+
 /* MESA_FORMAT_YCBCR *********************************************************/
 
 /* Fetch texel from 1D, 2D or 3D ycbcr texture, return 4 GLfloats.
index 096945a6432b4dc50c797bd543848a177c1a9675..06e6fd92fca9cec593f03fcd9eb70659c41031f9 100644 (file)
@@ -294,6 +294,32 @@ _mesa_choose_tex_format( GLcontext *ctx, GLint internalFormat,
       }
    }
 
+   if (ctx->VersionMajor * 10 + ctx->VersionMinor >= 31) {
+      switch (internalFormat) {
+         case GL_RED_SNORM:
+         case GL_R8_SNORM:
+            return MESA_FORMAT_SIGNED_R8;
+         case GL_RG_SNORM:
+         case GL_RG8_SNORM:
+            return MESA_FORMAT_SIGNED_RG88;
+         case GL_RGB_SNORM:
+         case GL_RGB8_SNORM:
+            return MESA_FORMAT_SIGNED_RGBX8888;
+         case GL_RGBA_SNORM:
+         case GL_RGBA8_SNORM:
+            return MESA_FORMAT_SIGNED_RGBA8888;
+         case GL_R16_SNORM:
+            return MESA_FORMAT_SIGNED_R_16;
+         case GL_RG16_SNORM:
+            return MESA_FORMAT_SIGNED_RG_16;
+         case GL_RGB16_SNORM:
+            return MESA_FORMAT_SIGNED_RGB_16;
+         case GL_RGBA16_SNORM:
+            return MESA_FORMAT_SIGNED_RGBA_16;
+         default:
+            ; /* fall-through */
+      }
+   }
 
 #if FEATURE_EXT_texture_sRGB
    if (ctx->Extensions.EXT_texture_sRGB) {
index 65e3fcaa9536d16702658070a0e946b771877550..94c0894de1f7244175a0851445a023de668429ba 100644 (file)
@@ -2551,6 +2551,147 @@ _mesa_texstore_dudv8(TEXSTORE_PARAMS)
    return GL_TRUE;
 }
 
+
+/**
+ * Store a texture in MESA_FORMAT_SIGNED_R8 format.
+ */
+static GLboolean
+_mesa_texstore_signed_r8(TEXSTORE_PARAMS)
+{
+   const GLuint texelBytes = _mesa_get_format_bytes(dstFormat);
+   const GLenum baseFormat = _mesa_get_format_base_format(dstFormat);
+
+   ASSERT(dstFormat == MESA_FORMAT_SIGNED_R8);
+   ASSERT(texelBytes == 1);
+
+   /* XXX look at adding optimized paths */
+   {
+      /* general path */
+      const GLfloat *tempImage = make_temp_float_image(ctx, dims,
+                                                 baseInternalFormat,
+                                                 baseFormat,
+                                                 srcWidth, srcHeight, srcDepth,
+                                                 srcFormat, srcType, srcAddr,
+                                                 srcPacking);
+      const GLfloat *srcRow = tempImage;
+      GLint img, row, col;
+      if (!tempImage)
+         return GL_FALSE;
+      _mesa_adjust_image_for_convolution(ctx, dims, &srcWidth, &srcHeight);
+      for (img = 0; img < srcDepth; img++) {
+         GLubyte *dstRow = (GLubyte *) dstAddr
+            + dstImageOffsets[dstZoffset + img] * texelBytes
+            + dstYoffset * dstRowStride
+            + dstXoffset * texelBytes;
+         for (row = 0; row < srcHeight; row++) {
+            GLubyte *dstB = (GLubyte *) dstRow;
+            for (col = 0; col < srcWidth; col++) {
+               dstB[col] = FLOAT_TO_BYTE_TEX(srcRow[RCOMP]);
+            }
+            dstRow += dstRowStride;
+         }
+      }
+      free((void *) tempImage);
+   }
+   return GL_TRUE;
+}
+
+
+/**
+ * Store a texture in MESA_FORMAT_SIGNED_RG88 format.
+ */
+static GLboolean
+_mesa_texstore_signed_rg88(TEXSTORE_PARAMS)
+{
+   const GLuint texelBytes = _mesa_get_format_bytes(dstFormat);
+   const GLenum baseFormat = _mesa_get_format_base_format(dstFormat);
+
+   ASSERT(dstFormat == MESA_FORMAT_SIGNED_RG88);
+   ASSERT(texelBytes == 1);
+
+   /* XXX look at adding optimized paths */
+   {
+      /* general path */
+      const GLfloat *tempImage = make_temp_float_image(ctx, dims,
+                                                 baseInternalFormat,
+                                                 baseFormat,
+                                                 srcWidth, srcHeight, srcDepth,
+                                                 srcFormat, srcType, srcAddr,
+                                                 srcPacking);
+      const GLfloat *srcRow = tempImage;
+      GLint img, row, col;
+      if (!tempImage)
+         return GL_FALSE;
+      _mesa_adjust_image_for_convolution(ctx, dims, &srcWidth, &srcHeight);
+      for (img = 0; img < srcDepth; img++) {
+         GLubyte *dstRow = (GLubyte *) dstAddr
+            + dstImageOffsets[dstZoffset + img] * texelBytes
+            + dstYoffset * dstRowStride
+            + dstXoffset * texelBytes;
+         for (row = 0; row < srcHeight; row++) {
+            GLushort *dstUS = (GLushort *) dstRow;
+            for (col = 0; col < srcWidth; col++) {
+               dstUS[col] = PACK_COLOR_88(FLOAT_TO_BYTE_TEX(srcRow[RCOMP]),
+                                          FLOAT_TO_BYTE_TEX(srcRow[GCOMP]));
+            }
+            dstRow += dstRowStride;
+         }
+      }
+      free((void *) tempImage);
+   }
+   return GL_TRUE;
+}
+
+
+/**
+ * Store a texture in MESA_FORMAT_SIGNED_RGBX8888.
+ */
+static GLboolean
+_mesa_texstore_signed_rgbx8888(TEXSTORE_PARAMS)
+{
+   const GLuint texelBytes = _mesa_get_format_bytes(dstFormat);
+   const GLenum baseFormat = _mesa_get_format_base_format(dstFormat);
+
+   ASSERT(dstFormat == MESA_FORMAT_SIGNED_RGBX8888);
+   ASSERT(texelBytes == 4);
+
+   {
+      /* general path */
+      const GLfloat *tempImage = make_temp_float_image(ctx, dims,
+                                                 baseInternalFormat,
+                                                 baseFormat,
+                                                 srcWidth, srcHeight, srcDepth,
+                                                 srcFormat, srcType, srcAddr,
+                                                 srcPacking);
+      const GLfloat *srcRow = tempImage;
+      GLint img, row, col;
+      if (!tempImage)
+         return GL_FALSE;
+      _mesa_adjust_image_for_convolution(ctx, dims, &srcWidth, &srcHeight);
+      for (img = 0; img < srcDepth; img++) {
+         GLubyte *dstRow = (GLubyte *) dstAddr
+            + dstImageOffsets[dstZoffset + img] * texelBytes
+            + dstYoffset * dstRowStride
+            + dstXoffset * texelBytes;
+         for (row = 0; row < srcHeight; row++) {
+            GLuint *dstUI = (GLuint *) dstRow;
+            for (col = 0; col < srcWidth; col++) {
+               dstUI[col] = PACK_COLOR_8888( FLOAT_TO_BYTE_TEX(srcRow[RCOMP]),
+                                             FLOAT_TO_BYTE_TEX(srcRow[GCOMP]),
+                                             FLOAT_TO_BYTE_TEX(srcRow[BCOMP]),
+                                             0xff );
+               srcRow += 4;
+            }
+            dstRow += dstRowStride;
+         }
+      }
+      free((void *) tempImage);
+   }
+   return GL_TRUE;
+}
+
+
+
 /**
  * Store a texture in MESA_FORMAT_SIGNED_RGBA8888 or MESA_FORMAT_SIGNED_RGBA8888_REV
  */
@@ -2672,6 +2813,7 @@ _mesa_texstore_signed_rgba8888(TEXSTORE_PARAMS)
    return GL_TRUE;
 }
 
+
 /**
  * Store a combined depth/stencil texture image.
  */
@@ -3197,9 +3339,18 @@ texstore_funcs[MESA_FORMAT_COUNT] =
    { MESA_FORMAT_INTENSITY_FLOAT32, _mesa_texstore_rgba_float32 },
    { MESA_FORMAT_INTENSITY_FLOAT16, _mesa_texstore_rgba_float16 },
    { MESA_FORMAT_DUDV8, _mesa_texstore_dudv8 },
+
+   { MESA_FORMAT_SIGNED_R8, _mesa_texstore_signed_r8 },
+   { MESA_FORMAT_SIGNED_RG88, _mesa_texstore_signed_rg88 },
+   { MESA_FORMAT_SIGNED_RGBX8888, _mesa_texstore_signed_rgbx8888 },
+
    { MESA_FORMAT_SIGNED_RGBA8888, _mesa_texstore_signed_rgba8888 },
    { MESA_FORMAT_SIGNED_RGBA8888_REV, _mesa_texstore_signed_rgba8888 },
-   { MESA_FORMAT_SIGNED_RGBA_16, NULL },
+
+   { MESA_FORMAT_SIGNED_R_16, NULL/*_mesa_texstore_signed_r16*/ },
+   { MESA_FORMAT_SIGNED_RG_16, NULL/*_mesa_texstore_signed_rg16*/ },
+   { MESA_FORMAT_SIGNED_RGB_16, NULL/*_mesa_texstore_signed_rgb16*/ },
+   { MESA_FORMAT_SIGNED_RGBA_16, NULL/*_mesa_texstore_signed_rgba16*/ },
 };