Skip to content
Snippets Groups Projects

vkd3d-shader/spirv: Allow gradient sampling cube textures.

Merged Giovanni Mascellani requested to merge giomasce/vkd3d:etna into master
1 unresolved thread

Currently emitting gradient sampling assumes that the number of components of the gradient is the same as the number of components of offsets. This is not correct, because offsets are not allowed for cube textures, while gradient sampling is allowed for cube textures.

This commit splits the concepts of offset component count and gradient component count. The gradient component count is indeed equal to the offset component count for all the texture dimensions where the latter makes sense, but is also defined for cube textures.

This commit fixes the compilation of shaders in Star Wars Jedi: Survivor, which make use of gradient sampling a cube texture.

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading