pub struct Asset { /* private fields */ }Expand description
Wraps the corresponding Model I/O asset counterpart.
Implementations§
Source§impl Asset
impl Asset
Sourcepub fn new() -> Result<Self>
pub fn new() -> Result<Self>
Wraps the corresponding Model I/O initializer for the wrapped Model I/O asset counterpart.
Sourcepub fn from_url(path: impl AsRef<Path>) -> Result<Self>
pub fn from_url(path: impl AsRef<Path>) -> Result<Self>
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn can_import_file_extension(path_extension: &str) -> bool
pub fn can_import_file_extension(path_extension: &str) -> bool
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn can_export_file_extension(path_extension: &str) -> bool
pub fn can_export_file_extension(path_extension: &str) -> bool
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn info(&self) -> Result<AssetInfo>
pub fn info(&self) -> Result<AssetInfo>
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn export_to_url(&self, path: impl AsRef<Path>) -> Result<()>
pub fn export_to_url(&self, path: impl AsRef<Path>) -> Result<()>
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn count(&self) -> usize
pub fn count(&self) -> usize
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn bounding_box(&self) -> BoundingBox
pub fn bounding_box(&self) -> BoundingBox
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn bounding_box_at_time(&self, time: f64) -> BoundingBox
pub fn bounding_box_at_time(&self, time: f64) -> BoundingBox
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn url(&self) -> Option<String>
pub fn url(&self) -> Option<String>
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn frame_interval(&self) -> f64
pub fn frame_interval(&self) -> f64
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn set_frame_interval(&self, value: f64)
pub fn set_frame_interval(&self, value: f64)
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn start_time(&self) -> f64
pub fn start_time(&self) -> f64
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn set_start_time(&self, value: f64)
pub fn set_start_time(&self, value: f64)
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn end_time(&self) -> f64
pub fn end_time(&self) -> f64
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn set_end_time(&self, value: f64)
pub fn set_end_time(&self, value: f64)
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn up_axis(&self) -> [f32; 3]
pub fn up_axis(&self) -> [f32; 3]
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn set_up_axis(&self, axis: [f32; 3])
pub fn set_up_axis(&self, axis: [f32; 3])
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn object_at(&self, index: usize) -> Option<Object>
pub fn object_at(&self, index: usize) -> Option<Object>
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn object_at_path(&self, path: &str) -> Result<Option<Object>>
pub fn object_at_path(&self, path: &str) -> Result<Option<Object>>
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn add_object(&self, object: &Object)
pub fn add_object(&self, object: &Object)
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn remove_object(&self, object: &Object)
pub fn remove_object(&self, object: &Object)
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn mesh_at(&self, index: usize) -> Option<Mesh>
pub fn mesh_at(&self, index: usize) -> Option<Mesh>
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn meshes(&self) -> Vec<Mesh>
pub fn meshes(&self) -> Vec<Mesh>
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Sourcepub fn load_textures(&self)
pub fn load_textures(&self)
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.
Source§impl Asset
impl Asset
Sourcepub fn place_light_probes(
density: f32,
heuristic: ProbePlacement,
data_source: &LightProbeIrradianceDataSource,
) -> Result<Vec<LightProbe>>
pub fn place_light_probes( density: f32, heuristic: ProbePlacement, data_source: &LightProbeIrradianceDataSource, ) -> Result<Vec<LightProbe>>
Calls the corresponding Model I/O method on the wrapped Model I/O asset counterpart.