Trait BindingUtil

Source
pub trait BindingUtil {
    // Required methods
    fn create_binding_map<T>(
        &self,
        f: impl Fn(&dyn UniformMeta) -> T,
    ) -> FastHashMap<UniformBinding, T>;
    fn calculate_requirements<'a>(
        pass_meta: impl Iterator<Item = &'a Self>,
    ) -> BindingRequirements
       where Self: 'a;
}
Expand description

Trait for objects that can be used to create a binding map.

Required Methods§

Source

fn create_binding_map<T>( &self, f: impl Fn(&dyn UniformMeta) -> T, ) -> FastHashMap<UniformBinding, T>

Create the uniform binding map with the given reflection information.

Source

fn calculate_requirements<'a>( pass_meta: impl Iterator<Item = &'a Self>, ) -> BindingRequirements
where Self: 'a,

Calculate the number of required images for history.

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.

Implementations on Foreign Types§

Source§

impl BindingUtil for BindingMeta

Source§

fn create_binding_map<T>( &self, f: impl Fn(&dyn UniformMeta) -> T, ) -> FastHashMap<UniformBinding, T>

Source§

fn calculate_requirements<'a>( pass_meta: impl Iterator<Item = &'a Self>, ) -> BindingRequirements
where Self: 'a,

Implementors§