Skip to content

Commit

Permalink
Fix point light radius (#9493)
Browse files Browse the repository at this point in the history
# Objective

Fixes #9488

## Solution

Set point light radius to always be 0.0. Reading this value from glTF
would require using application specific extras property.

---

## Changelog

### Fixed

- #9488 Point Lights use Range for Radius when importing from GLTF
  • Loading branch information
Feilkin authored Aug 20, 2023
1 parent 756b044 commit a024a1f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crates/bevy_gltf/src/loader.rs
Original file line number Diff line number Diff line change
Expand Up @@ -858,7 +858,7 @@ fn load_node(
// For a point light, luminous power = 4 * pi * luminous intensity
intensity: light.intensity() * std::f32::consts::PI * 4.0,
range: light.range().unwrap_or(20.0),
radius: light.range().unwrap_or(0.0),
radius: 0.0,
..Default::default()
},
..Default::default()
Expand Down

0 comments on commit a024a1f

Please sign in to comment.