pub struct Interface {
limits: Limits,
resources: Arena<Resource>,
entry_points: HashMap<(ShaderStage, String), EntryPoint, BuildHasherDefault<FxHasher>>,
}Fields§
§limits: Limits§resources: Arena<Resource>§entry_points: HashMap<(ShaderStage, String), EntryPoint, BuildHasherDefault<FxHasher>>Implementations§
Source§impl Interface
impl Interface
fn populate( list: &mut Vec<Varying>, binding: Option<&Binding>, ty: Handle<Type>, arena: &UniqueArena<Type>, )
pub fn new(module: &Module, info: &ModuleInfo, limits: Limits) -> Self
pub fn finalize_entry_point_name( &self, stage: ShaderStage, entry_point_name: Option<&str>, ) -> Result<String, StageError>
Sourcepub fn check_stage(
&self,
layouts: &mut BindingLayoutSource<'_>,
shader_binding_sizes: &mut HashMap<ResourceBinding, BufferSize, BuildHasherDefault<FxHasher>>,
entry_point_name: &str,
shader_stage: ShaderStageForValidation,
inputs: StageIo,
) -> Result<StageIo, StageError>
pub fn check_stage( &self, layouts: &mut BindingLayoutSource<'_>, shader_binding_sizes: &mut HashMap<ResourceBinding, BufferSize, BuildHasherDefault<FxHasher>>, entry_point_name: &str, shader_stage: ShaderStageForValidation, inputs: StageIo, ) -> Result<StageIo, StageError>
Among other things, this implements some validation logic defined by the WebGPU spec. at https://www.w3.org/TR/webgpu/#abstract-opdef-validating-inter-stage-interfaces.
pub fn fragment_uses_dual_source_blending( &self, entry_point_name: &str, ) -> Result<bool, StageError>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Interface
impl RefUnwindSafe for Interface
impl Send for Interface
impl Sync for Interface
impl Unpin for Interface
impl UnwindSafe for Interface
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