Skip to content

Commit

Permalink
Pipeline type safety
Browse files Browse the repository at this point in the history
  • Loading branch information
Litherum authored and kainino0x committed Mar 18, 2019
1 parent 31f5fca commit 678d728
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion design/sketch.webidl
Original file line number Diff line number Diff line change
Expand Up @@ -572,10 +572,10 @@ interface GPUProgrammablePassEncoder {

// Allowed in both compute and render passes
void setBindGroup(u32 index, GPUBindGroup bindGroup, optional sequence<u64> dynamicOffsets);
void setPipeline((GPUComputePipeline or GPURenderPipeline) pipeline);
};

interface GPURenderPassEncoder : GPUProgrammablePassEncoder {
void setPipeline(GPURenderPipeline pipeline);
void setBlendColor(GPUColor color);
void setStencilReference(u32 reference);

Expand All @@ -596,6 +596,7 @@ interface GPURenderPassEncoder : GPUProgrammablePassEncoder {
};

interface GPUComputePassEncoder : GPUProgrammablePassEncoder {
void setPipeline(GPUComputePipeline pipeline);
void dispatch(u32 x, u32 y, u32 z);

// TODO add missing commands
Expand Down

0 comments on commit 678d728

Please sign in to comment.