aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/main/texstore.c
diff options
context:
space:
mode:
authorIan Romanick <[email protected]>2011-08-26 12:20:00 -0700
committerIan Romanick <[email protected]>2011-08-29 11:07:49 -0700
commit55d232a81566cf7ab8855c42e2ef1a280276a04c (patch)
treeb38fc84b73db9c96e23fe69654f40770eb74e045 /src/mesa/main/texstore.c
parent0c1b71665487fcaeffa8f4d7b5ad0ba425a2c169 (diff)
mesa: Remove all mention of MESA_FORMAT_CI8
Nothing in Mesa supports color-index textures, and most of the other infrastructure that could allow such support has already been removed. This puts the final nail in the coffin. Also clean out some GL_COLOR_INDEX comments in formats.c. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa/main/texstore.c')
-rw-r--r--src/mesa/main/texstore.c45
1 files changed, 0 insertions, 45 deletions
diff --git a/src/mesa/main/texstore.c b/src/mesa/main/texstore.c
index aac600e40de..e9915a7f070 100644
--- a/src/mesa/main/texstore.c
+++ b/src/mesa/main/texstore.c
@@ -2724,50 +2724,6 @@ _mesa_texstore_unorm8(TEXSTORE_PARAMS)
-static GLboolean
-_mesa_texstore_ci8(TEXSTORE_PARAMS)
-{
- const GLuint texelBytes = _mesa_get_format_bytes(dstFormat);
-
- (void) dims; (void) baseInternalFormat;
- ASSERT(dstFormat == MESA_FORMAT_CI8);
- ASSERT(texelBytes == 1);
- ASSERT(baseInternalFormat == GL_COLOR_INDEX);
-
- if (!ctx->_ImageTransferState &&
- !srcPacking->SwapBytes &&
- srcFormat == GL_COLOR_INDEX &&
- srcType == GL_UNSIGNED_BYTE) {
- /* simple memcpy path */
- memcpy_texture(ctx, dims,
- dstFormat, dstAddr, dstXoffset, dstYoffset, dstZoffset,
- dstRowStride,
- dstImageOffsets,
- srcWidth, srcHeight, srcDepth, srcFormat, srcType,
- srcAddr, srcPacking);
- }
- else {
- /* general path */
- GLint img, row;
- for (img = 0; img < srcDepth; img++) {
- GLubyte *dstRow = (GLubyte *) dstAddr
- + dstImageOffsets[dstZoffset + img] * texelBytes
- + dstYoffset * dstRowStride
- + dstXoffset * texelBytes;
- for (row = 0; row < srcHeight; row++) {
- const GLvoid *src = _mesa_image_address(dims, srcPacking,
- srcAddr, srcWidth, srcHeight, srcFormat, srcType, img, row, 0);
- _mesa_unpack_index_span(ctx, srcWidth, GL_UNSIGNED_BYTE, dstRow,
- srcType, src, srcPacking,
- ctx->_ImageTransferState);
- dstRow += dstRowStride;
- }
- }
- }
- return GL_TRUE;
-}
-
-
/**
* Texstore for _mesa_texformat_ycbcr or _mesa_texformat_ycbcr_REV.
*/
@@ -4392,7 +4348,6 @@ texstore_funcs[MESA_FORMAT_COUNT] =
{ MESA_FORMAT_L16, _mesa_texstore_unorm16 },
{ MESA_FORMAT_I8, _mesa_texstore_unorm8 },
{ MESA_FORMAT_I16, _mesa_texstore_unorm16 },
- { MESA_FORMAT_CI8, _mesa_texstore_ci8 },
{ MESA_FORMAT_YCBCR, _mesa_texstore_ycbcr },
{ MESA_FORMAT_YCBCR_REV, _mesa_texstore_ycbcr },
{ MESA_FORMAT_R8, _mesa_texstore_unorm8 },