pub struct RenderObject {
pub mesh: MeshId,
pub texture: Option<TextureId>,
pub transform: Transform,
pub material: Material,
pub visible: bool,
}Expand description
A renderable instance: a mesh, optional texture, transform, and material. 一个可渲染实例:一个网格、可选纹理、变换和材质。
Fields§
§mesh: MeshIdThe mesh to draw. 要绘制的网格。
texture: Option<TextureId>Optional texture applied on top of the material tint. 叠加在材质色调上的可选纹理。
transform: TransformPlacement in world space. 世界空间中的放置。
material: MaterialSurface shading parameters. 表面着色参数。
visible: boolWhether the object participates in rendering. 对象是否参与渲染。
Trait Implementations§
Source§impl Clone for RenderObject
impl Clone for RenderObject
Source§fn clone(&self) -> RenderObject
fn clone(&self) -> RenderObject
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for RenderObject
impl RefUnwindSafe for RenderObject
impl Send for RenderObject
impl Sync for RenderObject
impl Unpin for RenderObject
impl UnsafeUnpin for RenderObject
impl UnwindSafe for RenderObject
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