summaryrefslogtreecommitdiff
path: root/src/video_core/textures
diff options
context:
space:
mode:
authorFernandoS27 <fsahmkow27@gmail.com>2018-10-13 16:11:11 -0400
committerFernandoS27 <fsahmkow27@gmail.com>2018-10-13 16:11:11 -0400
commit1ff20d8538e7ed6a9121882afef4d73503667842 (patch)
tree16fcec0f19cb1bf7b64dd1754108114cc73df98d /src/video_core/textures
parente0ca938b222584cdbf9e03460171c03484882bd4 (diff)
Fix a Crash on Zelda BotW and Splatoon 2, and simplified LoadGLBuffer
Diffstat (limited to 'src/video_core/textures')
-rw-r--r--src/video_core/textures/decoders.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/video_core/textures/decoders.cpp b/src/video_core/textures/decoders.cpp
index 6693067f8..5dab47886 100644
--- a/src/video_core/textures/decoders.cpp
+++ b/src/video_core/textures/decoders.cpp
@@ -271,7 +271,7 @@ u32 BytesPerPixel(TextureFormat format) {
std::vector<u8> UnswizzleTexture(VAddr address, u32 tile_size, u32 bytes_per_pixel, u32 width,
u32 height, u32 depth, u32 block_height, u32 block_depth) {
- std::vector<u8> unswizzled_data(width * height * bytes_per_pixel);
+ std::vector<u8> unswizzled_data(width * height * depth * bytes_per_pixel);
CopySwizzledData(width / tile_size, height / tile_size, depth, bytes_per_pixel, bytes_per_pixel,
Memory::GetPointer(address), unswizzled_data.data(), true, block_height,
block_depth);