diff --git a/wgpu-core/src/pipeline.rs b/wgpu-core/src/pipeline.rs index 595e7e106..4d611b6eb 100644 --- a/wgpu-core/src/pipeline.rs +++ b/wgpu-core/src/pipeline.rs @@ -171,27 +171,23 @@ pub enum ImplicitLayoutError { /// Describes a compute pipeline. #[derive(Clone, Debug)] #[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] -pub struct ComputePipelineDescriptor<'a> { +pub struct ComputePipelineDescriptor< + 'a, + PLL = PipelineLayoutId, + SM = ShaderModuleId, + PLC = PipelineCacheId, +> { pub label: Label<'a>, /// The layout of bind groups for this pipeline. - pub layout: Option, + pub layout: Option, /// The compiled compute stage and its entry point. - pub stage: ProgrammableStageDescriptor<'a>, + pub stage: ProgrammableStageDescriptor<'a, SM>, /// The pipeline cache to use when creating this pipeline. - pub cache: Option, + pub cache: Option, } -/// Describes a compute pipeline. -#[derive(Clone, Debug)] -pub struct ResolvedComputePipelineDescriptor<'a> { - pub label: Label<'a>, - /// The layout of bind groups for this pipeline. - pub layout: Option>, - /// The compiled compute stage and its entry point. - pub stage: ResolvedProgrammableStageDescriptor<'a>, - /// The pipeline cache to use when creating this pipeline. - pub cache: Option>, -} +pub type ResolvedComputePipelineDescriptor<'a> = + ComputePipelineDescriptor<'a, Arc, Arc, Arc>; #[derive(Clone, Debug, Error)] #[non_exhaustive]