[−][src]Struct gltf::Gltf
glTF JSON wrapper plus binary payload.
Fields
document: Document
The glTF JSON wrapper.
blob: Option<Vec<u8>>
The glTF binary payload in the case of binary glTF.
Methods
impl Gltf
[src]
pub fn open<P>(path: P) -> Result<Self> where
P: AsRef<Path>,
[src]
P: AsRef<Path>,
Convenience function that loads glTF from the file system.
pub fn from_reader_without_validation<R>(reader: R) -> Result<Self> where
R: Read + Seek,
[src]
R: Read + Seek,
Loads glTF from a reader without performing validation checks.
pub fn from_reader<R>(reader: R) -> Result<Self> where
R: Read + Seek,
[src]
R: Read + Seek,
Loads glTF from a reader.
pub fn from_slice_without_validation(slice: &[u8]) -> Result<Self>
[src]
Loads glTF from a slice of bytes without performing validation checks.
pub fn from_slice(slice: &[u8]) -> Result<Self>
[src]
Loads glTF from a slice of bytes.
Methods from Deref<Target = Document>
ⓘImportant traits for Accessors<'a>pub fn accessors(&self) -> Accessors
[src]
Returns an Iterator
that visits the accessors of the glTF asset.
ⓘImportant traits for Animations<'a>pub fn animations(&self) -> Animations
[src]
Returns an Iterator
that visits the animations of the glTF asset.
ⓘImportant traits for Buffers<'a>pub fn buffers(&self) -> Buffers
[src]
Returns an Iterator
that visits the pre-loaded buffers of the glTF asset.
ⓘImportant traits for Cameras<'a>pub fn cameras(&self) -> Cameras
[src]
Returns an Iterator
that visits the cameras of the glTF asset.
pub fn default_scene(&self) -> Option<Scene>
[src]
Returns the default scene, if provided.
ⓘImportant traits for ExtensionsUsed<'a>pub fn extensions_used(&self) -> ExtensionsUsed
[src]
Returns the extensions referenced in this .document file.
ⓘImportant traits for ExtensionsRequired<'a>pub fn extensions_required(&self) -> ExtensionsRequired
[src]
Returns the extensions required to load and render this asset.
ⓘImportant traits for Images<'a>pub fn images(&self) -> Images
[src]
Returns an Iterator
that visits the pre-loaded images of the glTF asset.
ⓘImportant traits for Materials<'a>pub fn materials(&self) -> Materials
[src]
Returns an Iterator
that visits the materials of the glTF asset.
ⓘImportant traits for Meshes<'a>pub fn meshes(&self) -> Meshes
[src]
Returns an Iterator
that visits the meshes of the glTF asset.
ⓘImportant traits for Nodes<'a>pub fn nodes(&self) -> Nodes
[src]
Returns an Iterator
that visits the nodes of the glTF asset.
ⓘImportant traits for Samplers<'a>pub fn samplers(&self) -> Samplers
[src]
Returns an Iterator
that visits the samplers of the glTF asset.
ⓘImportant traits for Scenes<'a>pub fn scenes(&self) -> Scenes
[src]
Returns an Iterator
that visits the scenes of the glTF asset.
ⓘImportant traits for Skins<'a>pub fn skins(&self) -> Skins
[src]
Returns an Iterator
that visits the skins of the glTF asset.
ⓘImportant traits for Textures<'a>pub fn textures(&self) -> Textures
[src]
Returns an Iterator
that visits the textures of the glTF asset.
ⓘImportant traits for Views<'a>pub fn views(&self) -> Views
[src]
Returns an Iterator
that visits the pre-loaded buffer views of the glTF
asset.
Trait Implementations
impl Clone for Gltf
[src]
fn clone(&self) -> Gltf
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Deref for Gltf
[src]
impl DerefMut for Gltf
[src]
impl Debug for Gltf
[src]
Auto Trait Implementations
impl Sync for Gltf
impl Unpin for Gltf
impl Send for Gltf
impl UnwindSafe for Gltf
impl RefUnwindSafe for Gltf
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,