pub enum Asset {
Image(Arc<RasterBuf>),
Brush(OpaqueValue),
Features(OpaqueValue),
ScalarField(Arc<ScalarField>),
Sprite(Arc<SpriteSheet>),
Font(OpaqueValue),
Glyphs(OpaqueValue),
}Expand description
One asset fetched by an AssetLoader.
The shape is uniform across input kinds (images, brushes, feature
layers, …) so every source-style node consumes the host through the
same trait — like a shader sampling a typed uniform binding.
Features carries a type-erased payload; by convention the
concrete type is Arc<ezu_features::FeatureLayer>. Font and
Glyphs are likewise type-erased (by convention
Arc<ezu_core::text::Font> / Arc<ezu_core::text::SdfFontStack>)
so this crate gains no font or raster-drawing dependencies.
Variants§
Image(Arc<RasterBuf>)
Brush(OpaqueValue)
Features(OpaqueValue)
ScalarField(Arc<ScalarField>)
Sprite(Arc<SpriteSheet>)
A sprite atlas + name→rect index; the icon node crops named rects.
Font(OpaqueValue)
A loaded font face; the text node shapes and draws with it.
Glyphs(OpaqueValue)
A glyph-PBF (SDF) fontstack; the text node’s compat backend.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Asset
impl !UnwindSafe for Asset
impl Freeze for Asset
impl Send for Asset
impl Sync for Asset
impl Unpin for Asset
impl UnsafeUnpin for Asset
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
Mutably borrows from an owned value. Read more