diff options
author | Brian Paul <[email protected]> | 2005-09-15 01:06:19 +0000 |
---|---|---|
committer | Brian Paul <[email protected]> | 2005-09-15 01:06:19 +0000 |
commit | da9f65268db5d0468f91860d9ef9f244587c7f48 (patch) | |
tree | dc8124e6b3ef21576c735080b835dfd71f9aae7f /src/mesa/main/teximage.c | |
parent | 7fb9352fe4889b8069349bcac39df2aaef144278 (diff) |
New set_fetch_functions() to set a gl_texture_image's FetchTexel functions
from the gl_texture_format's functions.
Added "adaptor" functions to allow sampling a float-valued texture with
GLchans and vice versa. This will allow trimming down the number of
texture fetch routines.
Diffstat (limited to 'src/mesa/main/teximage.c')
-rw-r--r-- | src/mesa/main/teximage.c | 40 |
1 files changed, 0 insertions, 40 deletions
diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c index d4d023acda3..c19e5b0a5aa 100644 --- a/src/mesa/main/teximage.c +++ b/src/mesa/main/teximage.c @@ -2090,14 +2090,6 @@ _mesa_TexImage1D( GLenum target, GLint level, GLint internalFormat, ASSERT(texImage->TexFormat); - /* If driver didn't explicitly set this, use the defaults */ - if (!texImage->FetchTexelc) - texImage->FetchTexelc = texImage->TexFormat->FetchTexel1D; - if (!texImage->FetchTexelf) - texImage->FetchTexelf = texImage->TexFormat->FetchTexel1Df; - ASSERT(texImage->FetchTexelc); - ASSERT(texImage->FetchTexelf); - /* state update */ texObj->Complete = GL_FALSE; ctx->NewState |= _NEW_TEXTURE; @@ -2189,14 +2181,6 @@ _mesa_TexImage2D( GLenum target, GLint level, GLint internalFormat, ASSERT(texImage->TexFormat); - /* If driver didn't explicitly set these, use the defaults */ - if (!texImage->FetchTexelc) - texImage->FetchTexelc = texImage->TexFormat->FetchTexel2D; - if (!texImage->FetchTexelf) - texImage->FetchTexelf = texImage->TexFormat->FetchTexel2Df; - ASSERT(texImage->FetchTexelc); - ASSERT(texImage->FetchTexelf); - /* state update */ texObj->Complete = GL_FALSE; ctx->NewState |= _NEW_TEXTURE; @@ -2284,14 +2268,6 @@ _mesa_TexImage3D( GLenum target, GLint level, GLint internalFormat, ASSERT(texImage->TexFormat); - /* If driver didn't explicitly set these, use the defaults */ - if (!texImage->FetchTexelc) - texImage->FetchTexelc = texImage->TexFormat->FetchTexel3D; - if (!texImage->FetchTexelf) - texImage->FetchTexelf = texImage->TexFormat->FetchTexel3Df; - ASSERT(texImage->FetchTexelc); - ASSERT(texImage->FetchTexelf); - /* state update */ texObj->Complete = GL_FALSE; ctx->NewState |= _NEW_TEXTURE; @@ -2519,14 +2495,6 @@ _mesa_CopyTexImage1D( GLenum target, GLint level, ASSERT(texImage->TexFormat); - /* If driver didn't explicitly set these, use the defaults */ - if (!texImage->FetchTexelc) - texImage->FetchTexelc = texImage->TexFormat->FetchTexel1D; - if (!texImage->FetchTexelf) - texImage->FetchTexelf = texImage->TexFormat->FetchTexel1Df; - ASSERT(texImage->FetchTexelc); - ASSERT(texImage->FetchTexelf); - /* state update */ texObj->Complete = GL_FALSE; ctx->NewState |= _NEW_TEXTURE; @@ -2581,14 +2549,6 @@ _mesa_CopyTexImage2D( GLenum target, GLint level, GLenum internalFormat, ASSERT(texImage->TexFormat); - /* If driver didn't explicitly set these, use the defaults */ - if (!texImage->FetchTexelc) - texImage->FetchTexelc = texImage->TexFormat->FetchTexel2D; - if (!texImage->FetchTexelf) - texImage->FetchTexelf = texImage->TexFormat->FetchTexel2Df; - ASSERT(texImage->FetchTexelc); - ASSERT(texImage->FetchTexelf); - /* state update */ texObj->Complete = GL_FALSE; ctx->NewState |= _NEW_TEXTURE; |