mirror of
https://github.com/storytold/wgpu.git
synced 2026-11-21 23:11:01 +01:00
[core] Do not use IDs as default types in MeshState
Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
This commit is contained in:
1 parent
f24f333161
commit
2a3bfd351e
4 files changed
+6
-11
No files matched your search
+1
-1
@@ -661,7 +661,7 @@ impl Player {
|
||||
.zero_initialize_workgroup_memory,
|
||||
},
|
||||
});
|
||||
let resolved_mesh = wgc::pipeline::ResolvedMeshState {
|
||||
let resolved_mesh = wgc::pipeline::MeshState {
|
||||
stage: wgc::pipeline::ProgrammableStageDescriptor {
|
||||
module: self.resolve_shader_module_id(mesh_state.stage.module),
|
||||
entry_point: mesh_state.stage.entry_point,
|
||||
|
||||
@@ -11,8 +11,8 @@ use crate::{
|
||||
id::{self, AdapterId, DeviceId, QueueId, SurfaceId},
|
||||
instance::{self, Adapter, Surface},
|
||||
pipeline::{
|
||||
self, ProgrammableStageDescriptor, RenderPipelineVertexProcessor,
|
||||
ResolvedGeneralRenderPipelineDescriptor, ResolvedMeshState, TaskState,
|
||||
self, MeshState, ProgrammableStageDescriptor, RenderPipelineVertexProcessor,
|
||||
ResolvedGeneralRenderPipelineDescriptor, TaskState,
|
||||
},
|
||||
present,
|
||||
resource::{
|
||||
@@ -934,10 +934,7 @@ impl Global {
|
||||
constants: mesh.stage.constants.clone(),
|
||||
zero_initialize_workgroup_memory: mesh.stage.zero_initialize_workgroup_memory,
|
||||
};
|
||||
RenderPipelineVertexProcessor::Mesh(
|
||||
task_module,
|
||||
ResolvedMeshState { stage: mesh_stage },
|
||||
)
|
||||
RenderPipelineVertexProcessor::Mesh(task_module, MeshState { stage: mesh_stage })
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -815,7 +815,7 @@ impl<'a> IntoTrace for crate::pipeline::TaskState<'a> {
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a> IntoTrace for crate::pipeline::ResolvedMeshState<'a> {
|
||||
impl<'a> IntoTrace for crate::pipeline::MeshState<'a> {
|
||||
type Output = crate::pipeline::MeshState<'a, PointerId<markers::ShaderModule>>;
|
||||
fn into_trace(self) -> Self::Output {
|
||||
crate::pipeline::MeshState {
|
||||
|
||||
@@ -626,13 +626,11 @@ pub struct TaskState<'a, SM = Arc<ShaderModule>> {
|
||||
/// Describes the mesh shader in a mesh shader pipeline.
|
||||
#[derive(Clone, Debug)]
|
||||
#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
|
||||
pub struct MeshState<'a, SM = ShaderModuleId> {
|
||||
pub struct MeshState<'a, SM = Arc<ShaderModule>> {
|
||||
/// The compiled mesh stage and its entry point.
|
||||
pub stage: ProgrammableStageDescriptor<'a, SM>,
|
||||
}
|
||||
|
||||
pub type ResolvedMeshState<'a> = MeshState<'a, Arc<ShaderModule>>;
|
||||
|
||||
/// Describes a vertex processor for either a conventional or mesh shading
|
||||
/// pipeline architecture.
|
||||
///
|
||||
|
||||
Reference in new issue
Block a user