Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion examples/3d/shadow_biases.rs
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ fn toggle_light(
for mut light in &mut directional_lights {
light.illuminance = if light.illuminance == 0.0 {
*writer.text(*example_text, 4) = "DirectionalLight".to_string();
100000.0
light_consts::lux::AMBIENT_DAYLIGHT
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't AMBIENT_DAYLIGHT 10k? DIRECT_SUNLIGHT is 100k

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry. Didn't read the "Use the correct default so the brightness matches". Not sure these really match, but #20363 seems to change everything even more here anyway. I guess we need to figure out of this example should be overly bright or not. If not I think these should both be like the point light in #20363

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

directional lights are in lux, point lights are in lumens. having them be the same doesnt make much sense, but this does match because this constant is used in DirectionalLight::default, which is how the scene is constructed

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gotcha that makes sense. On bevy main the directional light is dimmer at first, then more closely matches the point light after switching back and forth. With this pr the directional light remains dimmer, not as closely matching the point light. Probably just doesn't matter.

} else {
0.0
};
Expand Down
Loading