Enum turbine_scene3d::Command
source · pub enum Command {
Show 28 variants
UseProgram(Program),
SetModelViewProjection(Matrix4Uniform),
SetModel(Matrix4Uniform),
SetView(Matrix4Uniform),
SetTexture(Texture),
SetF32(F32Uniform, f32),
SetVector2(Vector2Uniform, Vector2<f32>),
SetVector3(Vector3Uniform, Vector3<f32>),
SetMatrix4(Matrix4Uniform, Matrix4<f32>),
EnableCullFace,
DisableCullFace,
CullFaceFront,
CullFaceBack,
CullFaceFrontAndBack,
DrawTriangles(VertexArray, usize),
DrawTriangleStrip(VertexArray, usize),
DrawLines(VertexArray, usize),
DrawPoints(VertexArray, usize),
Translate(Vector3<f32>),
TranslateGlobal(Vector3<f32>),
Scale(Vector3<f32>),
RotateXDeg(f32),
RotateYDeg(f32),
RotateZDeg(f32),
RotateAxisDeg(Vector3<f32>, f32),
PushTransform,
PopTransform,
Draw(CommandList),
}
Expand description
Stores a scene command.
Variants
UseProgram(Program)
Use program.
SetModelViewProjection(Matrix4Uniform)
Set model-view-projection transform.
SetModel(Matrix4Uniform)
Set model transform.
SetView(Matrix4Uniform)
Set view transform.
SetTexture(Texture)
Set texture.
SetF32(F32Uniform, f32)
Set f32 uniform.
SetVector2(Vector2Uniform, Vector2<f32>)
Set 2D vector uniform.
SetVector3(Vector3Uniform, Vector3<f32>)
Set 3D vector uniform.
SetMatrix4(Matrix4Uniform, Matrix4<f32>)
Set matrx uniform.
EnableCullFace
Enable cull face.
DisableCullFace
Disable cull face.
CullFaceFront
Cull front face.
CullFaceBack
Cull back face.
CullFaceFrontAndBack
Cull both front and back face.
DrawTriangles(VertexArray, usize)
Draw triangles.
DrawTriangleStrip(VertexArray, usize)
Draw triangle strip.
DrawLines(VertexArray, usize)
Draw lines.
DrawPoints(VertexArray, usize)
Draw points.
Translate(Vector3<f32>)
Translate model.
TranslateGlobal(Vector3<f32>)
Translate model in global coordinates.
Scale(Vector3<f32>)
Scale model.
RotateXDeg(f32)
Rotate model around x axis with degrees.
RotateYDeg(f32)
Rotate model around y axis with degrees.
RotateZDeg(f32)
Rotate model around z axis with degrees.
RotateAxisDeg(Vector3<f32>, f32)
Rotate model around axis with degrees.
PushTransform
Push model transform to transform stack.
PopTransform
Pop model transform from transform stack.
Draw(CommandList)
Draw a command list.
Trait Implementations
impl Copy for Command
impl StructuralPartialEq for Command
Auto Trait Implementations
impl RefUnwindSafe for Command
impl Send for Command
impl Sync for Command
impl Unpin for Command
impl UnwindSafe for Command
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> Pointable for T
impl<T> Pointable for T
impl<T> SetParameter for T
impl<T> SetParameter for T
fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Resultwhere
T: Parameter<Self>,
fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Resultwhere
T: Parameter<Self>,
Sets
value
as a parameter of self
.