Crate veloren_common_assets
source ·Expand description
Load assets (images or voxel data) from files
Modules
Structs
- ASSETS 🔒The HashMap where all loaded assets are stored in.
- Lazy static to find and cache where the asset directory is. Cases we need to account for:
- A non-generic version of [
AssetCache
]. - The main structure of this crate, used to cache assets.
- Loads assets from Bincode encoded files.
- Loads assets as raw bytes.
- The error type which is used when loading an asset.
- Loads assets from JSON files.
- Loads assets from another type.
- Loads a value from a JSON file.
- Loads assets from RON files.
- A string that can easily be shared.
- Loads assets as a String.
Enums
- Represent tree of directory, result of [generate_tree].
Traits
- An asset is a type loadable from raw bytes.
- The Asset trait, which is implemented by all structures that have their data stored in the filesystem.
- An asset type that can load other kinds of assets.
- Assets that are loadable from directories
- Specifies how an asset is loaded.
- Bytes sources to load assets from.
Functions
- Return path to repository root by searching 10 directories back
- Loads directory and all files in it
- Loads directory and all files in it
- Helper function to Walk::generate(), prefer using it instead.
Type Definitions
- A boxed error