GL_(UN)PACK_SKIP_IMAGES should only be applied to 3D texture pack/unpacking
and ignored for 1D and 2D images. Need to pass in image dimensions (1,2,3) to the _mesa_image_address() function. This change gets propogated to some other routines. Also added new _mesa_image_address[123]d() convenience functions.
This commit is contained in:
@@ -717,7 +717,7 @@ _mesa_GetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvo
|
||||
if (ctx->Pack.BufferObj->Name) {
|
||||
/* pack min/max values into a PBO */
|
||||
GLubyte *buf;
|
||||
if (!_mesa_validate_pbo_access(&ctx->Pack, 2, 1, 1,
|
||||
if (!_mesa_validate_pbo_access(1, &ctx->Pack, 2, 1, 1,
|
||||
format, type, values)) {
|
||||
_mesa_error(ctx, GL_INVALID_OPERATION,
|
||||
"glGetMinMax(invalid PBO access)");
|
||||
@@ -801,7 +801,7 @@ _mesa_GetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, G
|
||||
if (ctx->Pack.BufferObj->Name) {
|
||||
/* pack min/max values into a PBO */
|
||||
GLubyte *buf;
|
||||
if (!_mesa_validate_pbo_access(&ctx->Pack, ctx->Histogram.Width, 1, 1,
|
||||
if (!_mesa_validate_pbo_access(1, &ctx->Pack, ctx->Histogram.Width, 1, 1,
|
||||
format, type, values)) {
|
||||
_mesa_error(ctx, GL_INVALID_OPERATION,
|
||||
"glGetHistogram(invalid PBO access)");
|
||||
|
Reference in New Issue
Block a user