Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit dadeffa

Browse files
null77Commit Bot
authored andcommitted
Capture/Replay: Fix stride in compressed texture caching.
We were saving "width" bytes instead of "width * pixelSize". This was causing incorrect rendering in T-Rex and Manhattan. Bug: angleproject:4488 Change-Id: Ib5d38aaf813fb26905aedc155cc13b9d1597ec4c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2109336 Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org>
1 parent f955fb4 commit dadeffa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/libANGLE/FrameCapture.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2813,7 +2813,7 @@ void FrameCapture::captureCompressedTextureData(const gl::Context *context, cons
28132813
GLint y = yindex + yoffset;
28142814
GLint pixelOffset = zindex * pixelDepthPitch + yindex * pixelRowPitch;
28152815
GLint levelOffset = z * levelDepthPitch + y * levelRowPitch + xoffset * pixelBytes;
2816-
memcpy(&levelData[levelOffset], &pixelData[pixelOffset], pixelWidth);
2816+
memcpy(&levelData[levelOffset], &pixelData[pixelOffset], pixelRowPitch);
28172817
}
28182818
}
28192819

0 commit comments

Comments
 (0)