mesa/main: validate GL_UNSIGNED_INT_10_10_10_2

Reviewed-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29835>
This commit is contained in:
Erik Faye-Lund 2024-06-10 11:52:54 +02:00 committed by Marge Bot
parent 9409113d26
commit ea6f960ec8

View file

@ -1744,6 +1744,10 @@ static bool
valid_texture_type_enum(const struct gl_context *ctx, GLenum type)
{
switch (type) {
case GL_UNSIGNED_INT_10_10_10_2:
/* not supported in GLESv3, unlike GL_UNSIGNED_INT_2_10_10_10_REV */
return _mesa_is_desktop_gl(ctx);
case GL_UNSIGNED_INT_2_10_10_10_REV:
return _mesa_has_texture_type_2_10_10_10_REV(ctx);