summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2017-12-13 19:14:36 +0100
committerMarek Olšák <[email protected]>2018-01-06 09:51:43 +0100
commit581507f10aaa8a0239c9152501ad6f79aa61a08e (patch)
treeded741d3a2ee1aa06c2215d853e1ae7e2bd356ba /src
parent2971f688e6444b315856e6ffd17b428b14262edf (diff)
mesa: remove dd_function_table::GetCompressedTexSubImage and clean it up
Reviewed-by: Ian Romanick <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/mesa/drivers/common/driverfuncs.c1
-rw-r--r--src/mesa/main/dd.h10
-rw-r--r--src/mesa/main/texgetimage.c23
-rw-r--r--src/mesa/main/texgetimage.h8
-rw-r--r--src/mesa/state_tracker/st_cb_texture.c1
5 files changed, 11 insertions, 32 deletions
diff --git a/src/mesa/drivers/common/driverfuncs.c b/src/mesa/drivers/common/driverfuncs.c
index ddb4bb6d6a1..94dc0e62753 100644
--- a/src/mesa/drivers/common/driverfuncs.c
+++ b/src/mesa/drivers/common/driverfuncs.c
@@ -101,7 +101,6 @@ _mesa_init_driver_functions(struct dd_function_table *driver)
driver->TestProxyTexImage = _mesa_test_proxy_teximage;
driver->CompressedTexImage = _mesa_store_compressed_teximage;
driver->CompressedTexSubImage = _mesa_store_compressed_texsubimage;
- driver->GetCompressedTexSubImage = _mesa_GetCompressedTexSubImage_sw;
driver->BindTexture = NULL;
driver->NewTextureObject = _mesa_new_texture_object;
driver->DeleteTexture = _mesa_delete_texture_object;
diff --git a/src/mesa/main/dd.h b/src/mesa/main/dd.h
index 4e4d2a6f37d..3455ddbd122 100644
--- a/src/mesa/main/dd.h
+++ b/src/mesa/main/dd.h
@@ -337,16 +337,6 @@ struct dd_function_table {
GLsizei width, GLsizei height, GLsizei depth,
GLenum format,
GLsizei imageSize, const GLvoid *data);
-
- /**
- * Called by glGetCompressedTexImage.
- */
- void (*GetCompressedTexSubImage)(struct gl_context *ctx,
- struct gl_texture_image *texImage,
- GLint xoffset, GLint yoffset,
- GLint zoffset, GLsizei width,
- GLsizei height, GLsizei depth,
- GLvoid *data);
/*@}*/
/**
diff --git a/src/mesa/main/texgetimage.c b/src/mesa/main/texgetimage.c
index 26cf3e5644e..c61842e39ad 100644
--- a/src/mesa/main/texgetimage.c
+++ b/src/mesa/main/texgetimage.c
@@ -761,16 +761,15 @@ _mesa_GetTexSubImage_sw(struct gl_context *ctx,
/**
- * This is the software fallback for Driver.GetCompressedTexSubImage().
- * All error checking will have been done before this routine is called.
+ * This function assumes that all error checking has been done.
*/
-void
-_mesa_GetCompressedTexSubImage_sw(struct gl_context *ctx,
- struct gl_texture_image *texImage,
- GLint xoffset, GLint yoffset,
- GLint zoffset, GLsizei width,
- GLint height, GLint depth,
- GLvoid *img)
+static void
+get_compressed_texsubimage_sw(struct gl_context *ctx,
+ struct gl_texture_image *texImage,
+ GLint xoffset, GLint yoffset,
+ GLint zoffset, GLsizei width,
+ GLint height, GLint depth,
+ GLvoid *img)
{
const GLuint dimensions =
_mesa_get_texture_dimensions(texImage->TexObject->Target);
@@ -1661,9 +1660,9 @@ get_compressed_texture_image(struct gl_context *ctx,
texImage = texObj->Image[firstFace + i][level];
assert(texImage);
- ctx->Driver.GetCompressedTexSubImage(ctx, texImage,
- xoffset, yoffset, zoffset,
- width, height, depth, pixels);
+ get_compressed_texsubimage_sw(ctx, texImage,
+ xoffset, yoffset, zoffset,
+ width, height, depth, pixels);
/* next cube face */
pixels = (GLubyte *) pixels + imageStride;
diff --git a/src/mesa/main/texgetimage.h b/src/mesa/main/texgetimage.h
index 63c75eb931d..3928e7abb7b 100644
--- a/src/mesa/main/texgetimage.h
+++ b/src/mesa/main/texgetimage.h
@@ -44,14 +44,6 @@ _mesa_GetTexSubImage_sw(struct gl_context *ctx,
struct gl_texture_image *texImage);
extern void
-_mesa_GetCompressedTexSubImage_sw(struct gl_context *ctx,
- struct gl_texture_image *texImage,
- GLint xoffset, GLint yoffset,
- GLint zoffset, GLsizei width,
- GLint height, GLint depth,
- GLvoid *data);
-
-extern void
_mesa_get_compressed_texture_image( struct gl_context *ctx,
struct gl_texture_object *texObj,
struct gl_texture_image *texImage,
diff --git a/src/mesa/state_tracker/st_cb_texture.c b/src/mesa/state_tracker/st_cb_texture.c
index 7766273381b..98f2443bb30 100644
--- a/src/mesa/state_tracker/st_cb_texture.c
+++ b/src/mesa/state_tracker/st_cb_texture.c
@@ -3180,7 +3180,6 @@ st_init_texture_functions(struct dd_function_table *functions)
/* compressed texture functions */
functions->CompressedTexImage = st_CompressedTexImage;
- functions->GetCompressedTexSubImage = _mesa_GetCompressedTexSubImage_sw;
functions->NewTextureObject = st_NewTextureObject;
functions->NewTextureImage = st_NewTextureImage;