bevy/crates/bevy_pbr/src/render
robtfm 503c2a9677 adjust cluster index for viewport origin (#5947)
# Objective

fixes #5946

## Solution

adjust cluster index calculation for viewport origin.

from reading point 2 of the rasterization algorithm description in https://gpuweb.github.io/gpuweb/#rasterization, it looks like framebuffer space (and so @bulitin(position)) is not meant to be adjusted for viewport origin, so we need to subtract that to get the right cluster index.

- add viewport origin to rust `ExtractedView` and wgsl `View` structs
- subtract from frag coord for cluster index calculation
2022-09-15 21:58:14 +00:00
..
clustered_forward.wgsl adjust cluster index for viewport origin (#5947) 2022-09-15 21:58:14 +00:00
depth.wgsl update wgpu to 0.13 (#5168) 2022-07-14 21:17:16 +00:00
light.rs adjust cluster index for viewport origin (#5947) 2022-09-15 21:58:14 +00:00
mesh_bindings.wgsl update wgpu to 0.13 (#5168) 2022-07-14 21:17:16 +00:00
mesh_functions.wgsl bevy_pbr: Fix tangent and normal normalization (#5666) 2022-08-18 21:54:40 +00:00
mesh_types.wgsl bevy_pbr: Fix tangent and normal normalization (#5666) 2022-08-18 21:54:40 +00:00
mesh_vertex_output.wgsl update wgpu to 0.13 (#5168) 2022-07-14 21:17:16 +00:00
mesh_view_bindings.wgsl update wgpu to 0.13 (#5168) 2022-07-14 21:17:16 +00:00
mesh_view_types.wgsl adjust cluster index for viewport origin (#5947) 2022-09-15 21:58:14 +00:00
mesh.rs Use 3 bits of PipelineKey to store MSAA sample count (#5826) 2022-08-30 03:00:39 +00:00
mesh.wgsl update wgpu to 0.13 (#5168) 2022-07-14 21:17:16 +00:00
mod.rs Materials and MaterialPlugin (#3428) 2021-12-25 21:45:43 +00:00
pbr_bindings.wgsl update wgpu to 0.13 (#5168) 2022-07-14 21:17:16 +00:00
pbr_functions.wgsl bevy_pbr: Fix tangent and normal normalization (#5666) 2022-08-18 21:54:40 +00:00
pbr_lighting.wgsl update wgpu to 0.13 (#5168) 2022-07-14 21:17:16 +00:00
pbr_types.wgsl update wgpu to 0.13 (#5168) 2022-07-14 21:17:16 +00:00
pbr.wgsl update wgpu to 0.13 (#5168) 2022-07-14 21:17:16 +00:00
shadows.wgsl Spotlights (#4715) 2022-07-08 19:57:43 +00:00
skinning.wgsl update wgpu to 0.13 (#5168) 2022-07-14 21:17:16 +00:00
utils.wgsl adjust cluster index for viewport origin (#5947) 2022-09-15 21:58:14 +00:00
wireframe.wgsl update wgpu to 0.13 (#5168) 2022-07-14 21:17:16 +00:00