OpenGL ES spec violation report on application.

Hello. I’m GPU driver engineer in Samsung S.LSI. I’m working on OpenGL ES driver.
I want to report a graphic bug which comes from violating OpenGL ES’ spec.


I can see you are using compressed textures GL_COMPRESSED_R11_EAC & GL_COMPRESSED_RGBA_ASTC_6x6 on glCompressedTexSubImage2D() API and copying it with glCopyImageSubData() API.

The problem is, subregion’s width & height are not aligned with block extents of compressed format.

Here’s the input OpenGL ES APIs we get from your application;

06-11 15:35:15.188 11852 12026 I ANGLE : EVENT: glCompressedTexSubImage3D(context = 2, target = GL_TEXTURE_2D_ARRAY, level = 0, xoffset = 0, yoffset = 0, zoffset = 0, width = 512, height = 512, depth = 1, format = GL_COMPRESSED_RGBA_ASTC_6x6, imageSize = 118336, data = 0x00000071007315b8)

06-11 15:35:15.189 11852 12026 I ANGLE : EVENT: glCopyImageSubData(context = 2, srcName = 646, srcTarget = GL_TEXTURE_2D, srcLevel = 0, srcX = 0, srcY = 0, srcZ = 0, dstName = 673, dstTarget = GL_TEXTURE_2D_ARRAY, dstLevel = 0, dstX = 0, dstY = 0, dstZ = 0, srcWidth = 512, srcHeight = 512, srcDepth = 1)

The OpenGL ES spec regarding glCopyImageSubData() says;

GL_INVALID_VALUE is generated if the dimensions of the either subregion exceeds the boundaries of the corresponding image object, or if the image format is compressed and the dimensions of the subregion fail to meet the alignment constraints of the format.

As the GL_COMPRESSED_RGBA_ASTC_6x6 compressed format has 6x6 of block extent, but your srcWidth(512) & srcHeight(512) is not aligned with 6.

I focused only to GL_COMPRESSED_RGBA_ASTC_6x6 here, but GL_COMPRESSED_R11_EAC also has problem (which has 4x4 block extent).

It would be very nice if your company fix this bug.


The regarding block extent table is described on Spec pdf as well, and I have attached below for you.(With rendering problem as well)