mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 04:48:08 +02:00
mesa/main: validate GL_UNSIGNED_INT_2_10_10_10_REV
This type is allowed in OpenGL 1.2, which is guaranteed on desktop GL. For OpenGL ES, it got introduced in EXT_texture_type_2_10_10_10_REV as well as OpenGL ES 3.0. However, we already require EXT_texture_type_2_10_10_10_REV for OpenGL ES 3.0 support, so just checking for the extension should be enough. We already have a helper that does all of the above, so let's use that one. Reviewed-by: Adam Jackson <ajax@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29835>
This commit is contained in:
parent
75cad45ab1
commit
9409113d26
1 changed files with 3 additions and 0 deletions
|
|
@ -1744,6 +1744,9 @@ static bool
|
|||
valid_texture_type_enum(const struct gl_context *ctx, GLenum type)
|
||||
{
|
||||
switch (type) {
|
||||
case GL_UNSIGNED_INT_2_10_10_10_REV:
|
||||
return _mesa_has_texture_type_2_10_10_10_REV(ctx);
|
||||
|
||||
case GL_UNSIGNED_INT_10F_11F_11F_REV:
|
||||
return _mesa_has_packed_float(ctx);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue