diff options
Diffstat (limited to 'src/mesa/main/texgetimage.c')
-rw-r--r-- | src/mesa/main/texgetimage.c | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/src/mesa/main/texgetimage.c b/src/mesa/main/texgetimage.c index 749d0b21313..e43f33677fd 100644 --- a/src/mesa/main/texgetimage.c +++ b/src/mesa/main/texgetimage.c @@ -1895,6 +1895,36 @@ _mesa_GetCompressedTextureImageEXT(GLuint texture, GLenum target, GLint level, texObj = _mesa_lookup_or_create_texture(ctx, target, texture, false, true, caller); + + get_texture_image_dims(texObj, texObj->Target, level, + &width, &height, &depth); + + if (getcompressedteximage_error_check(ctx, texObj, texObj->Target, level, + 0, 0, 0, width, height, depth, + INT_MAX, pixels, caller)) { + return; + } + + get_compressed_texture_image(ctx, texObj, texObj->Target, level, + 0, 0, 0, width, height, depth, + pixels, caller); +} + + +void GLAPIENTRY +_mesa_GetCompressedMultiTexImageEXT(GLenum texunit, GLenum target, GLint level, + GLvoid *pixels) +{ + GET_CURRENT_CONTEXT(ctx); + struct gl_texture_object* texObj; + GLsizei width, height, depth; + static const char *caller = "glGetCompressedMultiTexImageEXT"; + + texObj = _mesa_get_texobj_by_target_and_texunit(ctx, target, + texunit - GL_TEXTURE0, + false, + caller); + get_texture_image_dims(texObj, texObj->Target, level, &width, &height, &depth); |