Crate fyrox_resource

source ·
Expand description

Resource management

Re-exports§

Modules§

  • A module for creating resources by their UUIDs. It is used to make resource system type-agnostic yet serializable/deserializable. Type UUID is saved together with resource state and used later on deserialization to create a default instance of corresponding resource.
  • Resource manager timed entry. It holds strong reference for a resource and a simple timer variable. When someone uses a resource, the timer variable is reset to default resource lifetime. Timer gradually decreases its value and once it reaches zero, the entry is deleted. The inner resource might still be in use (have a strong reference to it), the resource data will be deleted once no one uses the resource.
  • Resource event handling.
  • Resource dependency graph. See ResourceDependencyGraph docs for more info.
  • Provides an interface for IO operations that a resource loader will use, this facilliates things such as loading assets within archive files
  • Resource loader. It manages resource loading.
  • Resource manager controls loading and lifetime of resource in the engine.
  • Resource import options common traits.
  • A module that handles resource states.
  • A module for untyped resources. See UntypedResource docs for more info.

Structs§

Constants§

  • Type UUID of curve resource. It is defined here to load old versions of resources.
  • Type UUID of model resource. It is defined here to load old versions of resources.
  • Type UUID of shader resource. It is defined here to load old versions of resources.
  • Type UUID of sound buffer resource. It is defined here to load old versions of resources.
  • Type UUID of texture resource. It is defined here to load old versions of resources.

Traits§

  • A trait for resource data.
  • A trait for resource load error.
  • Extension trait for a resource data of a particular type, which adds additional functionality, such as: a way to get default state of the data (Default impl), a way to get data’s type uuid. The trait has automatic implementation for any type that implements ResourceData + Default + TypeUuidProvider traits.

Functions§

  • Collects all resources used by a given entity. Internally, it uses reflection to iterate over each field of every descendant sub-object of the entity. This function could be used to collect all resources used by an object, which could be useful if you’re building a resource dependency analyzer.