#[non_exhaustive]pub enum Geometry {
Show 13 variants
Box {
width: f32,
height: f32,
depth: f32,
},
Sphere {
radius: f32,
},
Plane {
width: f32,
height: f32,
},
Torus {
radius: f32,
tube: f32,
},
TorusKnot {
radius: f32,
tube: f32,
},
Cylinder {
radius_top: f32,
radius_bottom: f32,
height: f32,
},
Cone {
radius: f32,
height: f32,
},
Capsule {
radius: f32,
length: f32,
},
Icosahedron {
radius: f32,
},
Dodecahedron {
radius: f32,
},
Octahedron {
radius: f32,
},
Tetrahedron {
radius: f32,
},
Ring {
inner_radius: f32,
outer_radius: f32,
},
}Expand description
A primitive geometry. Sizes are in Three.js units.
A size that is not finite, or is negative, renders as the default size for that geometry.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Box
A box (box). Default 1,1,1.
Sphere
A sphere (sphere). Default radius 0.5.
Plane
A flat plane in the XY plane (plane). Default 1,1.
Torus
A torus (torus). Default 0.5,0.2.
TorusKnot
A torus knot (torus-knot). Default 0.5,0.15.
Cylinder
A cylinder (cylinder). Default 0.5,0.5,1.
Cone
A cone (cone). Default 0.5,1.
Capsule
A capsule (capsule). Default 0.3,0.6.
Icosahedron
An icosahedron (icosahedron). Default radius 0.5.
Dodecahedron
A dodecahedron (dodecahedron). Default radius 0.5.
Octahedron
An octahedron (octahedron). Default radius 0.5.
Tetrahedron
A tetrahedron (tetrahedron). Default radius 0.5.
Ring
A flat ring in the XY plane (ring). Default 0.25,0.5.
Implementations§
Trait Implementations§
impl Copy for Geometry
impl StructuralPartialEq for Geometry
Auto Trait Implementations§
impl Forget for Geometry
impl Freeze for Geometry
impl RefUnwindSafe for Geometry
impl Send for Geometry
impl Sync for Geometry
impl Unpin for Geometry
impl UnsafeUnpin for Geometry
impl UnwindSafe for Geometry
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> 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> ⓘ
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<T> Scoped for T
impl<T> Scoped for T
Source§fn scope(ctx: &PolicyContext) -> ScopeQuery<'_, Self>
fn scope(ctx: &PolicyContext) -> ScopeQuery<'_, Self>
Open a deferred
ScopeQuery for this type. Resolves the
registered scope at .load() time, not here.