mirror of
https://github.com/brl/mutter.git
synced 2024-12-25 12:32:05 +00:00
a2aa04f219
There were a few problems with the sub texture iterating code of sliced textures which were causing some conformance tests to fail when NPOT textures are disabled: • The spans are stored in un-normalized coordinates and the coordinates passed to the foreach function are normalized. The function was trying to un-normalize them before passing them to the span iterator code but it was using the wrong factor which was causing it to actually doubley normalize them. • The shim function to renormalize the coordinates before passing them to the callback was renormalizing the sub-texture coordinates instead of the virtual coordinates. The sub-texture coordinates are already in the right scale for whatever is the underlying texture so we don't need to touch them. Instead we need to normalize the virtual coordinates because these are coming from the un-normalized coordinates that we passed to the span iterating code. • The normalize factors passed to the span iterating were always 1. The code uses this normalizing factor to round the incoming coordinates to the nearest multiple of a full texture. It divides the coordinates by the factor rather than multiplying so it looks like we should be passing the virtual texture size here. Reviewed-by: Robert Bragg <robert@linux.intel.com> (cherry picked from commit c9773566b0ec0a17b34c440090529de8cff9609e) |
||
---|---|---|
.. | ||
config.env.in | ||
Makefile.am | ||
run-tests.sh | ||
test-alpha-test.c | ||
test-alpha-textures.c | ||
test-atlas-migration.c | ||
test-backface-culling.c | ||
test-bitmask.c | ||
test-blend-strings.c | ||
test-color-mask.c | ||
test-conform-main.c | ||
test-custom-attributes.c | ||
test-depth-test.c | ||
test-euler-quaternion.c | ||
test-fixed.c | ||
test-fixtures.c | ||
test-gles2-context.c | ||
test-just-vertex-shader.c | ||
test-launcher.sh.in | ||
test-layer-remove.c | ||
test-map-buffer-range.c | ||
test-materials.c | ||
test-multitexture.c | ||
test-no-gl-header.c | ||
test-npot-texture.c | ||
test-object.c | ||
test-offscreen.c | ||
test-path.c | ||
test-pipeline-uniforms.c | ||
test-pipeline-user-matrix.c | ||
test-pixel-buffer.c | ||
test-point-size.c | ||
test-point-sprite.c | ||
test-premult.c | ||
test-primitive.c | ||
test-read-texture-formats.c | ||
test-readpixels.c | ||
test-snippets.c | ||
test-sparse-pipeline.c | ||
test-sub-texture.c | ||
test-texture-3d.c | ||
test-texture-get-set-data.c | ||
test-texture-mipmaps.c | ||
test-texture-pixmap-x11.c | ||
test-texture-rectangle.c | ||
test-utils.c | ||
test-utils.h | ||
test-version.c | ||
test-vertex-buffer-contiguous.c | ||
test-vertex-buffer-interleved.c | ||
test-vertex-buffer-mutability.c | ||
test-viewport.c | ||
test-wrap-modes.c | ||
test-write-texture-formats.c |