pub enum DebugPrim {
Show 18 variants
Line {
start: Vec3,
end: Vec3,
color: Vec4,
width: f32,
},
Arrow {
from: Vec3,
to: Vec3,
color: Vec4,
head_size: f32,
},
Sphere {
center: Vec3,
radius: f32,
color: Vec4,
filled: bool,
},
Box {
center: Vec3,
half_extents: Vec3,
rotation: Quat,
color: Vec4,
filled: bool,
},
Cylinder {
base: Vec3,
top: Vec3,
radius: f32,
color: Vec4,
},
Cone {
apex: Vec3,
base_center: Vec3,
radius: f32,
color: Vec4,
},
Disc {
center: Vec3,
normal: Vec3,
radius: f32,
color: Vec4,
},
Grid {
center: Vec3,
normal: Vec3,
size: f32,
divisions: u32,
color: Vec4,
},
Cross {
center: Vec3,
size: f32,
color: Vec4,
},
Axes {
transform: Mat4,
size: f32,
},
Text {
pos: Vec3,
text: String,
color: Vec4,
scale: f32,
},
Quad {
corners: [Vec3; 4],
color: Vec4,
filled: bool,
},
Circle {
center: Vec3,
normal: Vec3,
radius: f32,
segments: u32,
color: Vec4,
},
Frustum {
view_proj_inv: Mat4,
color: Vec4,
},
Bezier {
p0: Vec3,
p1: Vec3,
p2: Vec3,
p3: Vec3,
steps: u32,
color: Vec4,
},
Point {
pos: Vec3,
size: f32,
color: Vec4,
},
Torus {
center: Vec3,
normal: Vec3,
major_r: f32,
minor_r: f32,
color: Vec4,
},
Spring {
start: Vec3,
end: Vec3,
coils: u32,
radius: f32,
color: Vec4,
},
}Variants§
Line
Arrow
Sphere
Box
Cylinder
Cone
Disc
Grid
Cross
Axes
Text
Quad
Circle
Frustum
Bezier
Point
Torus
Spring
Implementations§
Source§impl DebugPrim
impl DebugPrim
pub fn line(start: Vec3, end: Vec3, color: Vec4) -> Self
pub fn thin_line(start: Vec3, end: Vec3, color: Vec4) -> Self
pub fn thick_line(start: Vec3, end: Vec3, color: Vec4) -> Self
pub fn arrow(from: Vec3, to: Vec3, color: Vec4) -> Self
pub fn wire_sphere(center: Vec3, radius: f32, color: Vec4) -> Self
pub fn solid_sphere(center: Vec3, radius: f32, color: Vec4) -> Self
pub fn wire_box(center: Vec3, half: Vec3, rot: Quat, color: Vec4) -> Self
pub fn aabb(min: Vec3, max: Vec3, color: Vec4) -> Self
pub fn axes(transform: Mat4) -> Self
pub fn point(pos: Vec3, color: Vec4) -> Self
Trait Implementations§
Auto Trait Implementations§
impl Freeze for DebugPrim
impl RefUnwindSafe for DebugPrim
impl Send for DebugPrim
impl Sync for DebugPrim
impl Unpin for DebugPrim
impl UnsafeUnpin for DebugPrim
impl UnwindSafe for DebugPrim
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.