Skip to content

Commit

Permalink
Use view.view_proj for world projection (#4)
Browse files Browse the repository at this point in the history
  • Loading branch information
giraugh authored Jun 2, 2024
1 parent 97390ec commit 1691ab8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/render/lighting/lighting.wgsl
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ fn fragment(vo: FullscreenVertexOutput) -> @location(0) vec4<f32> {
// it to screen space in order to do things like compute distances (let
// alone render it in the correct place).
let point_light_screen_center =
world_to_screen(point_light.center, view.viewport.zw, view.projection);
world_to_screen(point_light.center, view.viewport.zw, view.view_proj);

// Compute the distance between the current position and the light's center.
// We multiply by the scale factor as otherwise our distance will always be
Expand Down

0 comments on commit 1691ab8

Please sign in to comment.