mirror of
https://github.com/skyline-emu/skyline.git
synced 2024-11-04 23:55:08 +01:00
Fix Texture Handle Offset Calculation
The texture handle offset calculation involved an incorrect shift by descriptor size which was found to be unnecessary and would result in an invalid handle that had the wrong TIC/TSC index and caused broken rendering.
This commit is contained in:
parent
aa57ec6d55
commit
0b2ce6a8f3
@ -949,7 +949,6 @@ namespace skyline::gpu::interconnect {
|
||||
.pImageInfo = imageInfo.data() + imageInfo.size(),
|
||||
});
|
||||
|
||||
u32 descriptorIndex{};
|
||||
for (auto &texture : program.info.texture_descriptors) {
|
||||
layoutBindings.push_back(vk::DescriptorSetLayoutBinding{
|
||||
.binding = bindingIndex++,
|
||||
@ -965,7 +964,7 @@ namespace skyline::gpu::interconnect {
|
||||
u32 textureIndex : 20;
|
||||
u32 samplerIndex : 12;
|
||||
};
|
||||
} handle{constantBuffer.Read<u32>(texture.cbuf_offset + (descriptorIndex++ << texture.size_shift))};
|
||||
} handle{constantBuffer.Read<u32>(texture.cbuf_offset)};
|
||||
|
||||
auto sampler{GetSampler(handle.samplerIndex)};
|
||||
auto textureView{GetPoolTextureView(handle.textureIndex)};
|
||||
|
Loading…
Reference in New Issue
Block a user