diff options
Diffstat (limited to 'ext/webgpu/src/render_pass.rs')
-rw-r--r-- | ext/webgpu/src/render_pass.rs | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/ext/webgpu/src/render_pass.rs b/ext/webgpu/src/render_pass.rs index 469bf727e..822b4c8c9 100644 --- a/ext/webgpu/src/render_pass.rs +++ b/ext/webgpu/src/render_pass.rs @@ -2,6 +2,7 @@ use deno_core::error::type_error; use deno_core::error::AnyError; +use deno_core::op; use deno_core::ResourceId; use deno_core::ZeroCopyBuf; use deno_core::{OpState, Resource}; @@ -32,6 +33,7 @@ pub struct RenderPassSetViewportArgs { max_depth: f32, } +#[op] pub fn op_webgpu_render_pass_set_viewport( state: &mut OpState, args: RenderPassSetViewportArgs, @@ -64,6 +66,7 @@ pub struct RenderPassSetScissorRectArgs { height: u32, } +#[op] pub fn op_webgpu_render_pass_set_scissor_rect( state: &mut OpState, args: RenderPassSetScissorRectArgs, @@ -91,6 +94,7 @@ pub struct RenderPassSetBlendConstantArgs { color: wgpu_types::Color, } +#[op] pub fn op_webgpu_render_pass_set_blend_constant( state: &mut OpState, args: RenderPassSetBlendConstantArgs, @@ -115,6 +119,7 @@ pub struct RenderPassSetStencilReferenceArgs { reference: u32, } +#[op] pub fn op_webgpu_render_pass_set_stencil_reference( state: &mut OpState, args: RenderPassSetStencilReferenceArgs, @@ -140,6 +145,7 @@ pub struct RenderPassBeginPipelineStatisticsQueryArgs { query_index: u32, } +#[op] pub fn op_webgpu_render_pass_begin_pipeline_statistics_query( state: &mut OpState, args: RenderPassBeginPipelineStatisticsQueryArgs, @@ -167,6 +173,7 @@ pub struct RenderPassEndPipelineStatisticsQueryArgs { render_pass_rid: ResourceId, } +#[op] pub fn op_webgpu_render_pass_end_pipeline_statistics_query( state: &mut OpState, args: RenderPassEndPipelineStatisticsQueryArgs, @@ -191,6 +198,7 @@ pub struct RenderPassWriteTimestampArgs { query_index: u32, } +#[op] pub fn op_webgpu_render_pass_write_timestamp( state: &mut OpState, args: RenderPassWriteTimestampArgs, @@ -219,6 +227,7 @@ pub struct RenderPassExecuteBundlesArgs { bundles: Vec<u32>, } +#[op] pub fn op_webgpu_render_pass_execute_bundles( state: &mut OpState, args: RenderPassExecuteBundlesArgs, @@ -258,6 +267,7 @@ pub struct RenderPassEndPassArgs { render_pass_rid: ResourceId, } +#[op] pub fn op_webgpu_render_pass_end_pass( state: &mut OpState, args: RenderPassEndPassArgs, @@ -289,6 +299,7 @@ pub struct RenderPassSetBindGroupArgs { dynamic_offsets_data_length: usize, } +#[op] pub fn op_webgpu_render_pass_set_bind_group( state: &mut OpState, args: RenderPassSetBindGroupArgs, @@ -342,6 +353,7 @@ pub struct RenderPassPushDebugGroupArgs { group_label: String, } +#[op] pub fn op_webgpu_render_pass_push_debug_group( state: &mut OpState, args: RenderPassPushDebugGroupArgs, @@ -371,6 +383,7 @@ pub struct RenderPassPopDebugGroupArgs { render_pass_rid: ResourceId, } +#[op] pub fn op_webgpu_render_pass_pop_debug_group( state: &mut OpState, args: RenderPassPopDebugGroupArgs, @@ -394,6 +407,7 @@ pub struct RenderPassInsertDebugMarkerArgs { marker_label: String, } +#[op] pub fn op_webgpu_render_pass_insert_debug_marker( state: &mut OpState, args: RenderPassInsertDebugMarkerArgs, @@ -424,6 +438,7 @@ pub struct RenderPassSetPipelineArgs { pipeline: u32, } +#[op] pub fn op_webgpu_render_pass_set_pipeline( state: &mut OpState, args: RenderPassSetPipelineArgs, @@ -455,6 +470,7 @@ pub struct RenderPassSetIndexBufferArgs { size: Option<u64>, } +#[op] pub fn op_webgpu_render_pass_set_index_buffer( state: &mut OpState, args: RenderPassSetIndexBufferArgs, @@ -496,6 +512,7 @@ pub struct RenderPassSetVertexBufferArgs { size: Option<u64>, } +#[op] pub fn op_webgpu_render_pass_set_vertex_buffer( state: &mut OpState, args: RenderPassSetVertexBufferArgs, @@ -538,6 +555,7 @@ pub struct RenderPassDrawArgs { first_instance: u32, } +#[op] pub fn op_webgpu_render_pass_draw( state: &mut OpState, args: RenderPassDrawArgs, @@ -569,6 +587,7 @@ pub struct RenderPassDrawIndexedArgs { first_instance: u32, } +#[op] pub fn op_webgpu_render_pass_draw_indexed( state: &mut OpState, args: RenderPassDrawIndexedArgs, @@ -598,6 +617,7 @@ pub struct RenderPassDrawIndirectArgs { indirect_offset: u64, } +#[op] pub fn op_webgpu_render_pass_draw_indirect( state: &mut OpState, args: RenderPassDrawIndirectArgs, @@ -627,6 +647,7 @@ pub struct RenderPassDrawIndexedIndirectArgs { indirect_offset: u64, } +#[op] pub fn op_webgpu_render_pass_draw_indexed_indirect( state: &mut OpState, args: RenderPassDrawIndexedIndirectArgs, |