#[repr(C)]pub enum AssetState {
Unsupported = -3,
NotFound = -2,
Error = -1,
None = 0,
Loading = 1,
LoadedMeta = 2,
Loaded = 3,
}
Expand description
StereoKit uses an asynchronous loading system to prevent assets from blocking execution! This means that asset loading systems will return an asset to you right away, even though it is still being processed in the background. https://stereokit.net/Pages/StereoKit/AssetState.html
see also: Tex::get_asset_state
Variants§
Unsupported = -3
This asset encountered an issue when parsing the source data. Either the format is unrecognized by StereoKit, or the data may be corrupt. Check the logs for additional details.
NotFound = -2
The asset data was not found! This is most likely an issue with a bad file path, or file permissions. Check the logs for additional details.
Error = -1
An unknown error occurred when trying to load the asset! Check the logs for additional details.
None = 0
This asset is in its default state. It has not been told to load anything, nor does it have any data!
Loading = 1
This asset is currently queued for loading, but hasn’t received any data yet. Attempting to access metadata or asset data will result in blocking the app’s execution until that data is loaded!
LoadedMeta = 2
This asset is still loading, but some of the higher level data is already available for inspection without blocking the app. Attempting to access the core asset data will result in blocking the app’s execution until that data is loaded!
Loaded = 3
This asset is completely loaded without issues, and is ready for use!
Trait Implementations§
Source§impl Clone for AssetState
impl Clone for AssetState
Source§fn clone(&self) -> AssetState
fn clone(&self) -> AssetState
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for AssetState
impl Debug for AssetState
Source§impl PartialEq for AssetState
impl PartialEq for AssetState
impl Copy for AssetState
impl Eq for AssetState
impl StructuralPartialEq for AssetState
Auto Trait Implementations§
impl Freeze for AssetState
impl RefUnwindSafe for AssetState
impl Send for AssetState
impl Sync for AssetState
impl Unpin for AssetState
impl UnwindSafe for AssetState
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.