mesa: put more info in glTexImage GL_OUT_OF_MEMORY error message
Give the user some idea about the size of the texture which caused the GL_OUT_OF_MEMORY error. Reviewed-by: Matt Turner <mattst88@gmail.com>
This commit is contained in:
@@ -3320,7 +3320,9 @@ teximage(struct gl_context *ctx, GLboolean compressed, GLuint dims,
|
|||||||
|
|
||||||
if (!sizeOK) {
|
if (!sizeOK) {
|
||||||
_mesa_error(ctx, GL_OUT_OF_MEMORY,
|
_mesa_error(ctx, GL_OUT_OF_MEMORY,
|
||||||
"glTexImage%uD(image too large)", dims);
|
"glTexImage%uD(image too large: %d x %d x %d, %s format)",
|
||||||
|
dims, width, height, depth,
|
||||||
|
_mesa_lookup_enum_by_nr(internalFormat));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user