pub struct RtReflectionSettings {
pub intensity: f32,
pub max_distance: f32,
}Expand description
Clamped RT-reflection tunables resolved from the authored asset fields. Held
by the backend and turned into a per-frame RtParams once the camera and
sun are known.
Fields§
§intensity: f32Reflection blend strength multiplier in [0, 1].
max_distance: f32World-space distance the reflection ray travels before it misses.
Implementations§
Source§impl RtReflectionSettings
impl RtReflectionSettings
Sourcepub fn resolve(intensity: f32, max_distance: f32) -> RtReflectionSettings
pub fn resolve(intensity: f32, max_distance: f32) -> RtReflectionSettings
Clamp the authored intensity / distance into a safe range.
Sourcepub fn params(&self, inputs: RtParamsInputs) -> RtParams
pub fn params(&self, inputs: RtParamsInputs) -> RtParams
Build the per-frame GPU uniform from these settings, the active camera, and the sun.
Trait Implementations§
Source§impl Clone for RtReflectionSettings
impl Clone for RtReflectionSettings
Source§fn clone(&self) -> RtReflectionSettings
fn clone(&self) -> RtReflectionSettings
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for RtReflectionSettings
Source§impl Debug for RtReflectionSettings
impl Debug for RtReflectionSettings
Source§impl PartialEq for RtReflectionSettings
impl PartialEq for RtReflectionSettings
impl StructuralPartialEq for RtReflectionSettings
Auto Trait Implementations§
impl Freeze for RtReflectionSettings
impl RefUnwindSafe for RtReflectionSettings
impl Send for RtReflectionSettings
impl Sync for RtReflectionSettings
impl Unpin for RtReflectionSettings
impl UnsafeUnpin for RtReflectionSettings
impl UnwindSafe for RtReflectionSettings
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
Mutably borrows from an owned value. Read more
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> ⓘ
Converts
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> ⓘ
Converts
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