pub enum ToneMapping {
None = 0,
Reinhard = 1,
Aces = 2,
Filmic = 3,
}
Expand description
Tone mapping is the process of mapping HDR color values computed with physical based rendering in the range [0,∞)
into LDR values that can be displayed on the screen in the range [0,1]
.
Variants§
None = 0
No tone mapping. Use this if you are rendering into an intermediate render target, ie. this is not the final render pass that renders into the screen.
Reinhard = 1
Photographic Tone Reproduction for Digital Images. <http://www.cmap.polytechnique.fr/~peyre/cours/x2005signal/hdr_photographic.pdf>
Aces = 2
ACES Filmic Tone Mapping Curve. <https://knarkowicz.wordpress.com/2016/01/06/aces-filmic-tone-mapping-curve/>
Filmic = 3
John Hables presentation “Uncharted 2 HDR Lighting”, Page 142 to 143. <http://www.gdcvault.com/play/1012459/Uncharted_2__HDR_Lighting>
Implementations§
Source§impl ToneMapping
impl ToneMapping
Sourcepub fn fragment_shader_source() -> &'static str
pub fn fragment_shader_source() -> &'static str
Returns the fragment shader source for applying the specified tone mapping in a shader.
Sourcepub fn use_uniforms(&self, program: &Program)
pub fn use_uniforms(&self, program: &Program)
Sends the uniform data needed to apply this tone mapping to the fragment shader.
Trait Implementations§
Source§impl Clone for ToneMapping
impl Clone for ToneMapping
Source§fn clone(&self) -> ToneMapping
fn clone(&self) -> ToneMapping
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more