Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "Tonemapping example refactor " #2

Merged
merged 1 commit into from
Feb 16, 2023
Merged
Show file tree
Hide file tree
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
8 changes: 4 additions & 4 deletions crates/bevy_core_pipeline/src/tonemapping/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -86,12 +86,12 @@ pub struct TonemappingPipeline {
#[reflect(FromReflect)]
pub enum TonemappingMethod {
None,
/// Suffers from lots of hue shifting, brights don't desaturate naturally.
/// Suffers from lots hue shifting, brights don't desaturate naturally.
Reinhard,
/// Old bevy default. Suffers from hue shifting, brights don't desaturate much at all.
ReinhardLuminance,
/// Bad
ACES,
Aces,
/// Very Good
AgX,
/// Also good
Expand Down Expand Up @@ -123,7 +123,7 @@ impl SpecializedRenderPipeline for TonemappingPipeline {
TonemappingMethod::ReinhardLuminance => {
shader_defs.push("TONEMAP_METHOD_REINHARD_LUMINANCE".into());
}
TonemappingMethod::ACES => shader_defs.push("TONEMAP_METHOD_ACES".into()),
TonemappingMethod::Aces => shader_defs.push("TONEMAP_METHOD_ACES".into()),
TonemappingMethod::AgX => shader_defs.push("TONEMAP_METHOD_AGX".into()),
TonemappingMethod::SomewhatBoringDisplayTransform => {
shader_defs.push("TONEMAP_METHOD_SOMEWHAT_BORING_DISPLAY_TRANSFORM".into())
Expand Down Expand Up @@ -264,7 +264,7 @@ pub fn get_lut_bindings<'a>(
TonemappingMethod::None
| TonemappingMethod::Reinhard
| TonemappingMethod::ReinhardLuminance
| TonemappingMethod::ACES
| TonemappingMethod::Aces
| TonemappingMethod::AgX
| TonemappingMethod::SomewhatBoringDisplayTransform => &tonemapping_luts.agx,
TonemappingMethod::TonyMcMapface => &tonemapping_luts.tony_mc_mapface,
Expand Down
2 changes: 1 addition & 1 deletion crates/bevy_pbr/src/material.rs
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ pub fn queue_material_meshes<M: Material>(
TonemappingMethod::ReinhardLuminance => {
MeshPipelineKey::TONEMAP_METHOD_REINHARD_LUMINANCE
}
TonemappingMethod::ACES => MeshPipelineKey::TONEMAP_METHOD_ACES,
TonemappingMethod::Aces => MeshPipelineKey::TONEMAP_METHOD_ACES,
TonemappingMethod::AgX => MeshPipelineKey::TONEMAP_METHOD_AGX,
TonemappingMethod::SomewhatBoringDisplayTransform => {
MeshPipelineKey::TONEMAP_METHOD_SOMEWHAT_BORING_DISPLAY_TRANSFORM
Expand Down
2 changes: 1 addition & 1 deletion crates/bevy_sprite/src/mesh2d/material.rs
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ pub fn queue_material2d_meshes<M: Material2d>(
TonemappingMethod::ReinhardLuminance => {
Mesh2dPipelineKey::TONEMAP_METHOD_REINHARD_LUMINANCE
}
TonemappingMethod::ACES => Mesh2dPipelineKey::TONEMAP_METHOD_ACES,
TonemappingMethod::Aces => Mesh2dPipelineKey::TONEMAP_METHOD_ACES,
TonemappingMethod::AgX => Mesh2dPipelineKey::TONEMAP_METHOD_AGX,
TonemappingMethod::SomewhatBoringDisplayTransform => {
Mesh2dPipelineKey::TONEMAP_METHOD_SOMEWHAT_BORING_DISPLAY_TRANSFORM
Expand Down
Loading