assimp::scene

Struct Scene

Source
pub struct Scene<'a>(/* private fields */);
Expand description

The Scene type is the root container for all imported scene data.

Implementations§

Source§

impl<'a> Scene<'a>

Source

pub fn is_incomplete(&self) -> bool

Returns true if the imported scene is not complete.

Source

pub fn is_validated(&self) -> bool

Returns true if the imported scene was successfully validated by the validate_data_structure post-process step.

Source

pub fn has_validation_warning(&self) -> bool

Returns true if any warnings were generated by the validate_data_structure post-process step. The details of the warnings are written to the output log.

Source

pub fn is_non_verbose_format(&self) -> bool

Returns true if the join_identical_vertices post-process step was run.

Source

pub fn is_terrain(&self) -> bool

Returns true if the imported mesh contained height-map terrain data.

Source

pub fn root_node(&self) -> Node<'_>

Returns the root node of the scene hierarchy

Source

pub fn num_meshes(&self) -> u32

Returns the number of meshes in the scene.

Source

pub fn mesh_iter(&self) -> MeshIter<'_>

Returns an iterator over all the meshes in the scene.

Source

pub fn mesh(&self, id: usize) -> Option<Mesh<'_>>

Return an individual mesh from the scene.

Source

pub fn num_materials(&self) -> u32

Returns the number of materials in the scene.

Source

pub fn material_iter(&self) -> MaterialIter<'_>

Returns an iterator over all the materials in the scene.

Source

pub fn num_animations(&self) -> u32

Returns the number of animations in the scene.

Source

pub fn animation_iter(&self) -> AnimationIter<'_>

Returns an iterator over all the animations in the scene.

Source

pub fn animation(&self, id: usize) -> Option<Animation<'_>>

Return an individual animation from the scene.

Source

pub fn num_textures(&self) -> u32

Returns the number of animations in the scene.

Source

pub fn texture_iter(&self) -> TextureIter<'_>

Returns an iterator over all the textures in the scene.

Source

pub fn num_lights(&self) -> u32

Returns the number of lights in the scene.

Source

pub fn light_iter(&self) -> LightIter<'_>

Returns an iterator over all the lights in the scene.

Source

pub fn num_cameras(&self) -> u32

Returns the number of cameras in the scene.

Source

pub fn camera_iter(&self) -> CameraIter<'_>

Returns an iterator over all the cameras in the scene.

Methods from Deref<Target = AiScene>§

Source

pub fn has_meshes(&self) -> bool

Source

pub fn has_materials(&self) -> bool

Source

pub fn has_lights(&self) -> bool

Source

pub fn has_textures(&self) -> bool

Source

pub fn has_cameras(&self) -> bool

Source

pub fn has_animations(&self) -> bool

Trait Implementations§

Source§

impl<'a> Deref for Scene<'a>

Source§

type Target = AiScene

The resulting type after dereferencing.
Source§

fn deref<'b>(&'b self) -> &'b AiScene

Dereferences the value.
Source§

impl<'a> Drop for Scene<'a>

Source§

fn drop(&mut self)

Executes the destructor for this type. Read more

Auto Trait Implementations§

§

impl<'a> Freeze for Scene<'a>

§

impl<'a> RefUnwindSafe for Scene<'a>

§

impl<'a> !Send for Scene<'a>

§

impl<'a> !Sync for Scene<'a>

§

impl<'a> Unpin for Scene<'a>

§

impl<'a> UnwindSafe for Scene<'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<P, T> Receiver for P
where P: Deref<Target = T> + ?Sized, T: ?Sized,

Source§

type Target = T

🔬This is a nightly-only experimental API. (arbitrary_self_types)
The target type on which the method may be called.
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.