Skip to content

lima: fix glCopyTexSubImage2D

Andreas Baierl requested to merge rellla/mesa:lima-fix-texture-reload into master

The reload texture descriptor needs to take care of the mipmap level and the layer in case of GL_TEXTURE_CUBE_MAP.

glCopyTexSubImage2D triggers the lima_blit function which ends in a draw. A reload is necessary. The reload texture descriptor is always built with just one mipmap level, but this needs to be the level we want to reload, not just 0. We also have to take care of the cubemap face.

This fixes the following dEQP tests:

dEQP-GLES2.functional.texture.specification.basic_copytexsubimage2d.2d_rgb
dEQP-GLES2.functional.texture.specification.basic_copytexsubimage2d.2d_rgba
dEQP-GLES2.functional.texture.specification.basic_copytexsubimage2d.cube_rgb
dEQP-GLES2.functional.texture.specification.basic_copytexsubimage2d.cube_rgba

Signed-off-by: Andreas Baierl ichgeh@imkreisrum.de

Edited by Andreas Baierl

Merge request reports

Loading