Enum webgpu::WebGPURequest
source · pub enum WebGPURequest {
Show 38 variants
BufferMapAsync {
sender: IpcSender<WebGPUResponseResult>,
buffer_id: BufferId,
device_id: DeviceId,
host_map: HostMap,
map_range: Range<u64>,
},
BufferMapComplete(BufferId),
CommandEncoderFinish {
command_encoder_id: CommandEncoderId,
device_id: DeviceId,
is_error: bool,
},
CopyBufferToBuffer {
command_encoder_id: CommandEncoderId,
source_id: BufferId,
source_offset: BufferAddress,
destination_id: BufferId,
destination_offset: BufferAddress,
size: BufferAddress,
},
CopyBufferToTexture {
command_encoder_id: CommandEncoderId,
source: ImageCopyBuffer,
destination: ImageCopyTexture,
copy_size: Extent3d,
},
CopyTextureToBuffer {
command_encoder_id: CommandEncoderId,
source: ImageCopyTexture,
destination: ImageCopyBuffer,
copy_size: Extent3d,
},
CopyTextureToTexture {
command_encoder_id: CommandEncoderId,
source: ImageCopyTexture,
destination: ImageCopyTexture,
copy_size: Extent3d,
},
CreateBindGroup {
device_id: DeviceId,
bind_group_id: BindGroupId,
descriptor: BindGroupDescriptor<'static>,
},
CreateBindGroupLayout {
device_id: DeviceId,
bind_group_layout_id: BindGroupLayoutId,
descriptor: Option<BindGroupLayoutDescriptor<'static>>,
},
CreateBuffer {
device_id: DeviceId,
buffer_id: BufferId,
descriptor: Option<BufferDescriptor<'static>>,
},
CreateCommandEncoder {
device_id: DeviceId,
command_encoder_id: CommandEncoderId,
label: Option<Cow<'static, str>>,
},
CreateComputePipeline {
device_id: DeviceId,
compute_pipeline_id: ComputePipelineId,
descriptor: ComputePipelineDescriptor<'static>,
implicit_ids: Option<(PipelineLayoutId, Vec<BindGroupLayoutId>)>,
},
CreateContext(IpcSender<ExternalImageId>),
CreatePipelineLayout {
device_id: DeviceId,
pipeline_layout_id: PipelineLayoutId,
descriptor: PipelineLayoutDescriptor<'static>,
},
CreateRenderPipeline {
device_id: DeviceId,
render_pipeline_id: RenderPipelineId,
descriptor: Option<RenderPipelineDescriptor<'static>>,
implicit_ids: Option<(PipelineLayoutId, Vec<BindGroupLayoutId>)>,
},
CreateSampler {
device_id: DeviceId,
sampler_id: SamplerId,
descriptor: SamplerDescriptor<'static>,
},
CreateShaderModule {
device_id: DeviceId,
program_id: ShaderModuleId,
program: String,
label: Option<String>,
},
CreateSwapChain {
device_id: DeviceId,
buffer_ids: ArrayVec<BufferId, PRESENTATION_BUFFER_COUNT>,
external_id: u64,
sender: IpcSender<ImageKey>,
image_desc: ImageDescriptor,
image_data: ImageData,
},
CreateTexture {
device_id: DeviceId,
texture_id: TextureId,
descriptor: Option<TextureDescriptor<'static>>,
},
CreateTextureView {
texture_id: TextureId,
texture_view_id: TextureViewId,
device_id: DeviceId,
descriptor: Option<TextureViewDescriptor<'static>>,
},
DestroyBuffer(BufferId),
DestroyDevice(DeviceId),
DestroySwapChain {
external_id: u64,
image_key: ImageKey,
},
DestroyTexture(TextureId),
Exit(IpcSender<()>),
FreeCommandBuffer(CommandBufferId),
FreeDevice(DeviceId),
RenderBundleEncoderFinish {
render_bundle_encoder: RenderBundleEncoder,
descriptor: RenderBundleDescriptor<'static>,
render_bundle_id: RenderBundleId,
device_id: DeviceId,
},
RequestAdapter {
sender: IpcSender<WebGPUResponseResult>,
options: RequestAdapterOptions,
ids: SmallVec<[AdapterId; 4]>,
},
RequestDevice {
sender: IpcSender<WebGPUResponseResult>,
adapter_id: WebGPUAdapter,
descriptor: DeviceDescriptor<Option<String>>,
device_id: DeviceId,
pipeline_id: PipelineId,
},
RunComputePass {
command_encoder_id: CommandEncoderId,
compute_pass: Option<ComputePass>,
},
RunRenderPass {
command_encoder_id: CommandEncoderId,
render_pass: Option<RenderPass>,
},
Submit {
queue_id: QueueId,
command_buffers: Vec<CommandBufferId>,
},
SwapChainPresent {
external_id: u64,
texture_id: TextureId,
encoder_id: CommandEncoderId,
},
UnmapBuffer {
buffer_id: BufferId,
device_id: DeviceId,
array_buffer: IpcSharedMemory,
is_map_read: bool,
offset: u64,
size: u64,
},
UpdateWebRenderData {
buffer_id: BufferId,
external_id: u64,
buffer_size: usize,
},
WriteBuffer {
queue_id: QueueId,
buffer_id: BufferId,
buffer_offset: u64,
data: IpcSharedMemory,
},
WriteTexture {
queue_id: QueueId,
texture_cv: ImageCopyTexture,
data_layout: ImageDataLayout,
size: Extent3d,
data: IpcSharedMemory,
},
}
Variants§
BufferMapAsync
Fields
§
sender: IpcSender<WebGPUResponseResult>
BufferMapComplete(BufferId)
CommandEncoderFinish
CopyBufferToBuffer
Fields
§
command_encoder_id: CommandEncoderId
§
source_offset: BufferAddress
§
destination_offset: BufferAddress
§
size: BufferAddress
CopyBufferToTexture
CopyTextureToBuffer
CopyTextureToTexture
CreateBindGroup
CreateBindGroupLayout
Fields
§
bind_group_layout_id: BindGroupLayoutId
§
descriptor: Option<BindGroupLayoutDescriptor<'static>>
CreateBuffer
CreateCommandEncoder
CreateComputePipeline
Fields
§
compute_pipeline_id: ComputePipelineId
§
descriptor: ComputePipelineDescriptor<'static>
§
implicit_ids: Option<(PipelineLayoutId, Vec<BindGroupLayoutId>)>
CreateContext(IpcSender<ExternalImageId>)
CreatePipelineLayout
CreateRenderPipeline
Fields
§
render_pipeline_id: RenderPipelineId
§
descriptor: Option<RenderPipelineDescriptor<'static>>
§
implicit_ids: Option<(PipelineLayoutId, Vec<BindGroupLayoutId>)>
CreateSampler
CreateShaderModule
CreateSwapChain
Fields
§
image_desc: ImageDescriptor
CreateTexture
CreateTextureView
DestroyBuffer(BufferId)
DestroyDevice(DeviceId)
DestroySwapChain
DestroyTexture(TextureId)
Exit(IpcSender<()>)
FreeCommandBuffer(CommandBufferId)
FreeDevice(DeviceId)
RenderBundleEncoderFinish
Fields
§
render_bundle_encoder: RenderBundleEncoder
§
descriptor: RenderBundleDescriptor<'static>
§
render_bundle_id: RenderBundleId
RequestAdapter
RequestDevice
Fields
§
sender: IpcSender<WebGPUResponseResult>
§
adapter_id: WebGPUAdapter
§
descriptor: DeviceDescriptor<Option<String>>
§
pipeline_id: PipelineId
RunComputePass
RunRenderPass
Submit
SwapChainPresent
UnmapBuffer
Fields
§
array_buffer: IpcSharedMemory
UpdateWebRenderData
WriteBuffer
WriteTexture
Trait Implementations§
source§impl Debug for WebGPURequest
impl Debug for WebGPURequest
source§impl<'de> Deserialize<'de> for WebGPURequest
impl<'de> Deserialize<'de> for WebGPURequest
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more