gfx-rs / gfx

[maintenance mode] A low-overhead Vulkan-like GPU API for Rust.
http://gfx-rs.github.io/
Apache License 2.0
5.35k stars 548 forks source link

dx12: Resource array bindings #1748

Open msiglreith opened 6 years ago

msiglreith commented 6 years ago

Vulkan bindings and dx12 bindings differ for resource arrays. One (slot, binding) pair in Vulkan can hold multiple resources, while in dx12 this has to be realized via an array (slot, binding) .. (slot, binding+n). In the current implementation the binding specified in the SPIR-V shaders are directly mapped to BaseShaderRegister resulting in possible overlaps.

The mapping needs also be adjusted on HLSL shader creation from SPIR-V.

kvark commented 6 years ago

This could be seen as a bug or as a missing feature (resource array support on DX12). Anyhow, we should be able to fix it internally even after the release, so I'm dropping the milestone.