pub trait Vertex: Pod {
// Required method
fn layout() -> VertexBufferLayout<'static>;
}Expand description
A trait for vertex types that can be used in GPU buffers.
Types implementing this trait must be Pod (plain old data) and provide
their vertex buffer layout for use in render pipelines.
Required Methods§
Sourcefn layout() -> VertexBufferLayout<'static>
fn layout() -> VertexBufferLayout<'static>
Returns the vertex buffer layout describing the attributes.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".