pub enum Semantic {
Position,
Normal,
Tangent(u8),
TexCoord(u8),
Color(u8),
Joints(u8),
Weights(u8),
ShaderInput(u8),
Point(u8),
}Expand description
A vertex attribute’s meaning.
Variants§
Position
Normal
Tangent(u8)
Tangent set: xyz tangent, w the bitangent sign. Set 0 is glTF’s standard TANGENT.
TexCoord(u8)
u right, v down: (0, 0) is the image’s top-left corner (glTF). Readers of bottom-left conventions store 1 - v.
Color(u8)
Joints(u8)
Weights(u8)
ShaderInput(u8)
Opaque per-vertex shader data, bound by the game’s input index and passed through untransformed. Geometry passes must copy it through; a pass that cannot preserve it must refuse ShaderInput by name. glTF has no attribute for them: a GLB primase writes leaves them out, and its writer counts them.
Point(u8)
A point per vertex in the mesh’s own space (xyz, three floats), bound by the game’s input index: a pivot a
vertex program turns the vertex about (a billboard card’s centre). Whatever moves the positions moves it the same
way (Moves::Point). glTF has no attribute for it: a GLB primase writes leaves it out, and its writer counts it.
Implementations§
Trait Implementations§
impl Copy for Semantic
impl Eq for Semantic
Source§impl From<Semantic> for Attribute
A shader input reads a vertex attribute by the same meaning a mesh stream has.
impl From<Semantic> for Attribute
A shader input reads a vertex attribute by the same meaning a mesh stream has.
Source§impl Ord for Semantic
impl Ord for Semantic
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialOrd for Semantic
impl PartialOrd for Semantic
impl StructuralPartialEq for Semantic
Auto Trait Implementations§
impl Forget for Semantic
impl Freeze for Semantic
impl RefUnwindSafe for Semantic
impl Send for Semantic
impl Sync for Semantic
impl Unpin for Semantic
impl UnsafeUnpin for Semantic
impl UnwindSafe for Semantic
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
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<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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.