pub struct PostProcessSettings {Show 20 fields
pub enabled: bool,
pub tone_mapping: ToneMapping,
pub exposure: f32,
pub ssao: bool,
pub bloom: bool,
pub bloom_threshold: f32,
pub bloom_intensity: f32,
pub fxaa: bool,
pub ssaa_factor: u32,
pub contact_shadows: bool,
pub contact_shadow_max_distance: f32,
pub contact_shadow_steps: u32,
pub contact_shadow_thickness: f32,
pub edl_enabled: bool,
pub edl_radius: f32,
pub edl_strength: f32,
pub dof_enabled: bool,
pub dof_focal_distance: f32,
pub dof_focal_range: f32,
pub dof_max_blur_radius: f32,
}Expand description
Post-processing settings for the HDR render pipeline.
Passed via EffectsFrame::post_process each frame. When enabled is
false, the viewport renders directly to the output surface and all other
fields are ignored. The render() and render_viewport() entry points
support both paths; the paint_to / paint_viewport_to entry points are
always LDR regardless of this setting.
Transparent volume meshes (SceneFrame::transparent_volume_meshes) require
enabled = true – they are rendered via the OIT pass which only exists in
the HDR pipeline.
Fields§
§enabled: boolEnable the HDR render target and tone mapping pipeline. Default: true.
tone_mapping: ToneMappingTone mapping operator. Default: KhronosNeutral.
exposure: f32Pre-tone-mapping exposure multiplier. Default: 1.0.
ssao: boolEnable screen-space ambient occlusion.
bloom: boolEnable bloom.
bloom_threshold: f32HDR luminance threshold for bloom extraction. Default: 1.0.
bloom_intensity: f32Bloom contribution multiplier. Default: 0.1.
fxaa: boolEnable FXAA (Fast Approximate Anti-Aliasing) fullscreen pass.
ssaa_factor: u32Supersampling anti-aliasing factor. 1 = off, 2 = 2x, 4 = 4x.
When > 1, scene geometry is rendered at ssaa_factor x resolution and
downsampled before post-processing. Produces sharper edges than FXAA at
the cost of rendering ssaa_factor^2 times more pixels. Intended for
offline or screenshot use, not interactive rendering.
contact_shadows: boolEnable screen-space contact shadows (thin shadows at object-ground contact).
contact_shadow_max_distance: f32Maximum ray-march distance in view space. Default: 0.5.
contact_shadow_steps: u32Number of ray-march steps. Default: 16.
contact_shadow_thickness: f32Depth thickness threshold for occlusion test. Default: 0.1.
edl_enabled: boolEnable Eye-Dome Lighting depth enhancement.
Samples a ring of 8 depth neighbors and darkens pixels at depth discontinuities, making point clouds and surface edges easier to read at any viewing distance.
edl_radius: f32EDL sample ring radius in pixels. Default: 1.0.
edl_strength: f32EDL darkening strength (0.0 = none, higher = stronger). Default: 1.0.
dof_enabled: boolEnable depth of field bokeh blur.
Pixels whose linearized depth is outside
[dof_focal_distance - dof_focal_range, dof_focal_distance + dof_focal_range]
are blurred with a disc kernel whose radius scales up to dof_max_blur_radius
pixels.
dof_focal_distance: f32View-space depth of the in-focus plane (same units as the scene). Default: 5.0.
dof_focal_range: f32Half-width of the sharp band around the focal plane (view-space units). Default: 1.0.
dof_max_blur_radius: f32Maximum blur kernel radius in pixels at maximum defocus. Default: 8.0.
Trait Implementations§
Source§impl Clone for PostProcessSettings
impl Clone for PostProcessSettings
Source§fn clone(&self) -> PostProcessSettings
fn clone(&self) -> PostProcessSettings
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for PostProcessSettings
impl Debug for PostProcessSettings
Auto Trait Implementations§
impl Freeze for PostProcessSettings
impl RefUnwindSafe for PostProcessSettings
impl Send for PostProcessSettings
impl Sync for PostProcessSettings
impl Unpin for PostProcessSettings
impl UnsafeUnpin for PostProcessSettings
impl UnwindSafe for PostProcessSettings
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be
downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further
downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSend for T
impl<T> DowncastSend for T
Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.