You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi everyone. I created a specialized mesh pipeline, but different from the official docs, I still want to leverage the material system to calculate the fragment color.
Here's my current version, and my question in the comments:
implSpecializedMeshPipelineforCustomPipeline{typeKey = MeshPipelineKey;fnspecialize(&self,key:Self::Key,layout:&MeshVertexBufferLayoutRef,) -> Result<RenderPipelineDescriptor,SpecializedMeshPipelineError>{letmut descriptor = self.mesh_pipeline.specialize(key, layout)?;// ...// What shall I write here to get and set the material bind group layout?
descriptor
.layout.insert(3, ???);Ok(descriptor)}}// ...// Set the material bind group heretypeDrawCustom = (SetItemPipeline,SetMeshViewBindGroup<0>,SetMeshViewBindingArrayBindGroup<1>,SetMeshBindGroup<2>,SetMaterialBindGroup<3>,DrawMeshInstanced,);
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi everyone. I created a specialized mesh pipeline, but different from the official docs, I still want to leverage the material system to calculate the fragment color.
Here's my current version, and my question in the comments:
Beta Was this translation helpful? Give feedback.
All reactions