#[repr(C)]pub struct CompositeParams {
pub post: PostProcessParams,
pub fade: f32,
pub view_mode: u32,
pub far: f32,
}Expand description
Fragment constants for the composite pass: the authored post-process
tunables plus the scene-transition fade the backend owns. Pushed verbatim to
the composite fragment shader, so the layout must stay in sync with the
CompositeUniforms struct there. 48 bytes.
The fade is not a PostProcessParams field because that struct is resolved
from the PostProcessConfig asset and re-pushed whenever a settings slider
moves, which would reset an in-flight fade. It is also pushed to the bloom
prefilter, which has no use for it.
Fields§
§post: PostProcessParamsThe authored post-process tunables.
fade: f32Scene-transition fade to black in [0, 1]: 0 renders the composited
image untouched, 1 renders it fully black. The shader scales by
1 - fade in linear light on the HDR path and on the display-referred
result on the SDR path.
view_mode: u32The viewport’s G-buffer channel view as a ViewMode discriminant, or 0
for the normal scene path (Lit / Unlit / Wireframe all composite the
scene). Non-zero switches the fragment to visualize the matching
prepass channel.
far: f32Camera far plane, for normalizing the depth channel view.
Trait Implementations§
Source§impl Clone for CompositeParams
impl Clone for CompositeParams
Source§fn clone(&self) -> CompositeParams
fn clone(&self) -> CompositeParams
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for CompositeParams
Source§impl Debug for CompositeParams
impl Debug for CompositeParams
impl NoUninit for CompositeParams
Auto Trait Implementations§
impl Freeze for CompositeParams
impl RefUnwindSafe for CompositeParams
impl Send for CompositeParams
impl Sync for CompositeParams
impl Unpin for CompositeParams
impl UnsafeUnpin for CompositeParams
impl UnwindSafe for CompositeParams
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<S, T> Duplex<S> for Twhere
T: FromSample<S> + ToSample<S>,
Source§impl<S> FromSample<S> for S
impl<S> FromSample<S> for S
fn from_sample_(s: S) -> S
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 more