Struct three_d::io::Loaded [−][src]
pub struct Loaded<'a> { /* fields omitted */ }
Expand description
Implementations
impl<'a> Loaded<'a>
[src]
impl<'a> Loaded<'a>
[src]pub fn image<P: AsRef<Path>>(
&'a self,
path: P
) -> Result<CPUTexture<u8>, IOError>
[src]
pub fn image<P: AsRef<Path>>(
&'a self,
path: P
) -> Result<CPUTexture<u8>, IOError>
[src]Deserialize the loaded image resource at the given path into a CPUTexture using the image crate. The CPUTexture can then be used to create a Texture2D.
Feature
Only available when the image-io
feature is enabled.
pub fn cube_image<P: AsRef<Path>>(
&'a self,
right_path: P,
left_path: P,
top_path: P,
bottom_path: P,
front_path: P,
back_path: P
) -> Result<CPUTexture<u8>, IOError>
[src]
pub fn cube_image<P: AsRef<Path>>(
&'a self,
right_path: P,
left_path: P,
top_path: P,
bottom_path: P,
front_path: P,
back_path: P
) -> Result<CPUTexture<u8>, IOError>
[src]Deserialize the 6 loaded image resources at the given paths into a CPUTexture using the image crate. The CPUTexture can then be used to create a TextureCubeMap.
Feature
Only available when the image-io
feature is enabled.
impl<'a> Loaded<'a>
[src]
impl<'a> Loaded<'a>
[src]pub fn obj<P: AsRef<Path>>(
&'a self,
path: P
) -> Result<(Vec<CPUMesh>, Vec<CPUMaterial>), IOError>
[src]
pub fn obj<P: AsRef<Path>>(
&'a self,
path: P
) -> Result<(Vec<CPUMesh>, Vec<CPUMaterial>), IOError>
[src]Deserialize a loaded .obj file resource and .mtl material file resource (if present) into a list of meshes and materials. It uses the wavefront-obj crate.
Feature
Only available when the obj-io
feature is enabled.