Struct CommandEncoder
An object that encodes GPU operations.
struct CommandEncoder
;
A CommandEncoder can record RenderPasses, ComputePasses, and transfer operations between driver-managed resources like Buffers and Textures.
When finished recording, call CommandEncoder to obtain a CommandBuffer which may be submitted for execution.
Fields
| Name | Type | Description |
|---|---|---|
descriptor
|
const(__C | Describes a CommandEncoder.
|
id
|
__C | Handle identifier. |
Methods
| Name | Description |
|---|---|
beginComputePass
(descriptor)
|
Begins recording of a compute pass. |
beginRenderPass
(colorAttachments, label)
|
Begins recording of a render pass. |
beginRenderPass
(colorAttachment, depthStencilAttachment, label)
|
Begins recording of a render pass. |
beginRenderPass
(colorAttachments, depthStencilAttachment, label)
|
Begins recording of a render pass. |
beginRenderPass
(descriptor)
|
Begins recording of a render pass. |
copyBufferToTexture
(source, destination)
|
Copy data from a Buffer to a Texture.
|
copyBufferToTexture
(source, destination, copySize)
|
Copy data from a buffer to a texture. |
copyTextureToBuffer
(source, destination)
|
Copy data from a Texture to a Buffer.
|
copyTextureToBuffer
(source, destination, copySize)
|
Copy data from a Texture to a Buffer.
|
copyTextureToBuffer
(source, destination, copySize)
|
Copy data from a texture to a buffer. |
finish
()
|
Finishes recording and returns a CommandBuffer that can be submitted for execution.
|