summaryrefslogtreecommitdiffstats
path: root/src/mesa/swrast/s_texfetch.c
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2011-10-07 08:22:35 -0600
committerBrian Paul <[email protected]>2011-10-07 08:23:24 -0600
commitba69c4a0025e73ec2997795ddb4c3d6a210bfe32 (patch)
tree1d03526ff61be86a5a4a5309200885bb5ae554e7 /src/mesa/swrast/s_texfetch.c
parentd7477ad0a38a178d1e03f8064ee8245b46e24f1e (diff)
swrast: remove unused swrast_texture_image::FetchTexelc method
We only use the float-valued function now.
Diffstat (limited to 'src/mesa/swrast/s_texfetch.c')
-rw-r--r--src/mesa/swrast/s_texfetch.c62
1 files changed, 1 insertions, 61 deletions
diff --git a/src/mesa/swrast/s_texfetch.c b/src/mesa/swrast/s_texfetch.c
index 7573abda6dd..4bacf218b0b 100644
--- a/src/mesa/swrast/s_texfetch.c
+++ b/src/mesa/swrast/s_texfetch.c
@@ -1287,63 +1287,7 @@ _mesa_get_texel_store_func(gl_format format)
/**
- * Adaptor for fetching a GLchan texel from a float-valued texture.
- */
-static void
-fetch_texel_float_to_chan(const struct swrast_texture_image *texImage,
- GLint i, GLint j, GLint k, GLchan *texelOut)
-{
- GLfloat temp[4];
- GLenum baseFormat = _mesa_get_format_base_format(texImage->Base.TexFormat);
-
- ASSERT(texImage->FetchTexelf);
- texImage->FetchTexelf(texImage, i, j, k, temp);
- if (baseFormat == GL_DEPTH_COMPONENT ||
- baseFormat == GL_DEPTH_STENCIL_EXT) {
- /* just one channel */
- UNCLAMPED_FLOAT_TO_CHAN(texelOut[0], temp[0]);
- }
- else {
- /* four channels */
- UNCLAMPED_FLOAT_TO_CHAN(texelOut[0], temp[0]);
- UNCLAMPED_FLOAT_TO_CHAN(texelOut[1], temp[1]);
- UNCLAMPED_FLOAT_TO_CHAN(texelOut[2], temp[2]);
- UNCLAMPED_FLOAT_TO_CHAN(texelOut[3], temp[3]);
- }
-}
-
-
-#if 0
-/**
- * Adaptor for fetching a float texel from a GLchan-valued texture.
- */
-static void
-fetch_texel_chan_to_float(const struct swrast_texture_image *texImage,
- GLint i, GLint j, GLint k, GLfloat *texelOut)
-{
- GLchan temp[4];
- GLenum baseFormat = _mesa_get_format_base_format(texImage->TexFormat);
-
- ASSERT(texImage->FetchTexelc);
- texImage->FetchTexelc(texImage, i, j, k, temp);
- if (baseFormat == GL_DEPTH_COMPONENT ||
- baseFormat == GL_DEPTH_STENCIL_EXT) {
- /* just one channel */
- texelOut[0] = CHAN_TO_FLOAT(temp[0]);
- }
- else {
- /* four channels */
- texelOut[0] = CHAN_TO_FLOAT(temp[0]);
- texelOut[1] = CHAN_TO_FLOAT(temp[1]);
- texelOut[2] = CHAN_TO_FLOAT(temp[2]);
- texelOut[3] = CHAN_TO_FLOAT(temp[3]);
- }
-}
-#endif
-
-
-/**
- * Initialize the texture image's FetchTexelc and FetchTexelf methods.
+ * Initialize the texture image's FetchTexelf methods.
*/
static void
set_fetch_functions(struct swrast_texture_image *texImage, GLuint dims)
@@ -1358,10 +1302,6 @@ set_fetch_functions(struct swrast_texture_image *texImage, GLuint dims)
}
texImage->FetchTexelf = _mesa_get_texel_fetch_func(format, dims);
-
- texImage->FetchTexelc = fetch_texel_float_to_chan;
-
- ASSERT(texImage->FetchTexelc);
ASSERT(texImage->FetchTexelf);
}