pub enum ShadowUpdate {
EveryFrame,
Hybrid,
}Expand description
How often each cascaded-shadow-map slice is re-rendered. The shadow pass re-rasterizes all scene geometry into every cascade, so it is one of the heavier passes; updating distant cascades less often cuts that cost.
hybrid (the default) re-renders the nearest cascade every frame (so close
shadows stay crisp) and rotates through the farther cascades one per frame.
Distant shadows then lag a few frames while the camera moves, which is
imperceptible at that range. every_frame re-renders all cascades every
frame: pick it for scenes with fast-moving shadow casters where even distant
shadow lag is unacceptable. Each cascade is always primed (rendered once)
before it is sampled, so there is never missing shadow data.
Variants§
EveryFrame
Re-render every cascade every frame.
Hybrid
Re-render the near cascades every frame and the distant ones on a rotation.
Trait Implementations§
Source§impl Clone for ShadowUpdate
impl Clone for ShadowUpdate
Source§fn clone(&self) -> ShadowUpdate
fn clone(&self) -> ShadowUpdate
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 ShadowUpdate
Source§impl Debug for ShadowUpdate
impl Debug for ShadowUpdate
Source§impl Default for ShadowUpdate
impl Default for ShadowUpdate
Source§fn default() -> ShadowUpdate
fn default() -> ShadowUpdate
Source§impl<'de> Deserialize<'de> for ShadowUpdate
impl<'de> Deserialize<'de> for ShadowUpdate
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<ShadowUpdate, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<ShadowUpdate, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
impl Eq for ShadowUpdate
Source§impl PartialEq for ShadowUpdate
impl PartialEq for ShadowUpdate
Source§impl Serialize for ShadowUpdate
impl Serialize for ShadowUpdate
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
impl StructuralPartialEq for ShadowUpdate
Auto Trait Implementations§
impl Freeze for ShadowUpdate
impl RefUnwindSafe for ShadowUpdate
impl Send for ShadowUpdate
impl Sync for ShadowUpdate
impl Unpin for ShadowUpdate
impl UnsafeUnpin for ShadowUpdate
impl UnwindSafe for ShadowUpdate
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.