Specializable

Trait Specializable 

Source
pub trait Specializable {
    type Descriptor: PartialEq + Clone + Send + Sync;
    type CachedId: Clone + Send + Sync;

    // Required methods
    fn queue(
        pipeline_cache: &PipelineCache,
        descriptor: Self::Descriptor,
    ) -> Self::CachedId;
    fn get_descriptor(
        pipeline_cache: &PipelineCache,
        id: Self::CachedId,
    ) -> &Self::Descriptor;
}
Expand description

Defines a type that is able to be “specialized” and cached by creating and transforming its descriptor type. This is implemented for RenderPipeline and ComputePipeline, and likely will not have much utility for other types.

See docs on Specializer for more info.

Required Associated Types§

Required Methods§

Source

fn queue( pipeline_cache: &PipelineCache, descriptor: Self::Descriptor, ) -> Self::CachedId

Source

fn get_descriptor( pipeline_cache: &PipelineCache, id: Self::CachedId, ) -> &Self::Descriptor

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§