pub struct ReflectionCapture {Show 17 fields
pub id: u32,
pub name: String,
pub position: Vec3,
pub rotation: Quat,
pub shape: ReflectionCaptureShape,
pub influence_radius: f32,
pub box_half_extents: Vec3,
pub blend_distance: f32,
pub projection_mode: ReflectionProjectionMode,
pub projection_offset: Vec3,
pub resolution: CubemapResolution,
pub bake_status: ProbeBakeStatus,
pub importance: f32,
pub intensity: f32,
pub hdr_scale: f32,
pub cubemap_handle: Option<u64>,
pub mip_levels: u32,
}Fields§
§id: u32§name: String§position: Vec3§rotation: Quat§shape: ReflectionCaptureShape§influence_radius: f32§box_half_extents: Vec3§blend_distance: f32§projection_mode: ReflectionProjectionMode§projection_offset: Vec3§resolution: CubemapResolution§bake_status: ProbeBakeStatus§importance: f32§intensity: f32§hdr_scale: f32§cubemap_handle: Option<u64>GPU handle for the baked cubemap
mip_levels: u32Implementations§
Source§impl ReflectionCapture
impl ReflectionCapture
pub fn new_sphere( id: u32, name: impl Into<String>, position: Vec3, radius: f32, ) -> Self
pub fn new_box( id: u32, name: impl Into<String>, position: Vec3, half_extents: Vec3, ) -> Self
pub fn influence_at(&self, point: Vec3) -> f32
pub fn get_reflection_direction( &self, sample_dir: Vec3, world_pos: Vec3, ) -> Vec3
pub fn face_view_matrices(&self) -> [Mat4; 6]
pub fn memory_bytes(&self) -> u64
Trait Implementations§
Source§impl Clone for ReflectionCapture
impl Clone for ReflectionCapture
Auto Trait Implementations§
impl Freeze for ReflectionCapture
impl RefUnwindSafe for ReflectionCapture
impl Send for ReflectionCapture
impl Sync for ReflectionCapture
impl Unpin for ReflectionCapture
impl UnsafeUnpin for ReflectionCapture
impl UnwindSafe for ReflectionCapture
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,
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>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<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>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> 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)
Convert
&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)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.