diff options
author | Brian Paul <[email protected]> | 2012-01-02 11:55:39 -0700 |
---|---|---|
committer | Brian Paul <[email protected]> | 2012-01-02 11:55:39 -0700 |
commit | d69d287068e0a6b5e2f3c13b1f55335a9b6ce03b (patch) | |
tree | 345c179ac005aead301355bd3e60433a8abadde4 /src/mesa/main/texcompress_fxt1.c | |
parent | e833b98182ea7da142a57b385735be9e79776439 (diff) |
mesa: remove the dstX/Y/Zoffset params to _mesa_texstore() functions
The were always zero. When doing a sub-texture replacement we account
for the dstX/Y/Zoffsets when we map the texture image. So no need to
pass them into the texstore code anymore.
Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa/main/texcompress_fxt1.c')
-rw-r--r-- | src/mesa/main/texcompress_fxt1.c | 18 |
1 files changed, 2 insertions, 16 deletions
diff --git a/src/mesa/main/texcompress_fxt1.c b/src/mesa/main/texcompress_fxt1.c index d5c73e3b424..2480ffb38c3 100644 --- a/src/mesa/main/texcompress_fxt1.c +++ b/src/mesa/main/texcompress_fxt1.c @@ -64,14 +64,9 @@ _mesa_texstore_rgb_fxt1(TEXSTORE_PARAMS) const GLubyte *pixels; GLint srcRowStride; GLubyte *dst; - const GLint texWidth = dstRowStride * 8 / 16; /* a bit of a hack */ const GLubyte *tempImage = NULL; ASSERT(dstFormat == MESA_FORMAT_RGB_FXT1); - ASSERT(dstXoffset % 8 == 0); - ASSERT(dstYoffset % 4 == 0); - ASSERT(dstZoffset == 0); - (void) dstZoffset; if (srcFormat != GL_RGB || srcType != GL_UNSIGNED_BYTE || @@ -99,9 +94,7 @@ _mesa_texstore_rgb_fxt1(TEXSTORE_PARAMS) srcType) / sizeof(GLubyte); } - dst = _mesa_compressed_image_address(dstXoffset, dstYoffset, 0, - dstFormat, - texWidth, dstSlices[0]); + dst = dstSlices[0]; fxt1_encode(srcWidth, srcHeight, 3, pixels, srcRowStride, dst, dstRowStride); @@ -122,14 +115,9 @@ _mesa_texstore_rgba_fxt1(TEXSTORE_PARAMS) const GLubyte *pixels; GLint srcRowStride; GLubyte *dst; - GLint texWidth = dstRowStride * 8 / 16; /* a bit of a hack */ const GLubyte *tempImage = NULL; ASSERT(dstFormat == MESA_FORMAT_RGBA_FXT1); - ASSERT(dstXoffset % 8 == 0); - ASSERT(dstYoffset % 4 == 0); - ASSERT(dstZoffset == 0); - (void) dstZoffset; if (srcFormat != GL_RGBA || srcType != GL_UNSIGNED_BYTE || @@ -156,9 +144,7 @@ _mesa_texstore_rgba_fxt1(TEXSTORE_PARAMS) srcType) / sizeof(GLubyte); } - dst = _mesa_compressed_image_address(dstXoffset, dstYoffset, 0, - dstFormat, - texWidth, dstSlices[0]); + dst = dstSlices[0]; fxt1_encode(srcWidth, srcHeight, 4, pixels, srcRowStride, dst, dstRowStride); |