Commit 69efbed4 authored by bajones's avatar bajones Committed by Commit bot

Corrected test that blocked ES3 compressions formats with 2D textures.

GL_TEXTURE_3D is not valid with these formats, but 2D, 2D arrays, and Cubemaps are fine.

BUG=429053

Review URL: https://codereview.chromium.org/1133853002

Cr-Commit-Position: refs/heads/master@{#329017}
parent 3ecad604
...@@ -9014,7 +9014,7 @@ bool GLES2DecoderImpl::ValidateCompressedTexDimensions( ...@@ -9014,7 +9014,7 @@ bool GLES2DecoderImpl::ValidateCompressedTexDimensions(
"width, height, or depth invalid"); "width, height, or depth invalid");
return false; return false;
} }
if (target != GL_TEXTURE_2D_ARRAY) { if (target == GL_TEXTURE_3D) {
LOCAL_SET_GL_ERROR( LOCAL_SET_GL_ERROR(
GL_INVALID_OPERATION, function_name, GL_INVALID_OPERATION, function_name,
"target invalid for format"); "target invalid for format");
...@@ -9116,7 +9116,7 @@ bool GLES2DecoderImpl::ValidateCompressedTexSubDimensions( ...@@ -9116,7 +9116,7 @@ bool GLES2DecoderImpl::ValidateCompressedTexSubDimensions(
{ {
const int kBlockSize = 4; const int kBlockSize = 4;
GLsizei tex_width, tex_height; GLsizei tex_width, tex_height;
if (target != GL_TEXTURE_2D_ARRAY || if (target == GL_TEXTURE_3D ||
!texture->GetLevelSize(target, level, !texture->GetLevelSize(target, level,
&tex_width, &tex_height, nullptr) || &tex_width, &tex_height, nullptr) ||
(xoffset % kBlockSize) || (yoffset % kBlockSize) || (xoffset % kBlockSize) || (yoffset % kBlockSize) ||
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment