Readonly
mapReadonly
sizeReadonly
usageReturns an ArrayBuffer with the contents of the GPUBuffer in the given mapped range.
Optional
offset: numberOffset in bytes into the buffer to return buffer contents from.
Optional
size: numberSize in bytes of the ArrayBuffer to return.
Maps the given range of the GPUBuffer and resolves the returned Promise when the GPUBuffer's content is ready to be accessed with getMappedRange. The resolution of the returned Promise only indicates that the buffer has been mapped. It does not guarantee the completion of any other operations visible to the content timeline, and in particular does not imply that any other Promise returned from () or mapAsync on other GPUBuffers have resolved. The resolution of the Promise returned from onSubmittedWorkDone does imply the completion of mapAsync calls made prior to that call, on GPUBuffers last used exclusively on that queue.
Whether the buffer should be mapped for reading or writing.
Optional
offset: numberOffset in bytes into the buffer to the start of the range to map.
Optional
size: numberSize in bytes of the range to map.
Unmaps the mapped range of the GPUBuffer and makes its contents available for use by the GPU again.
Generated using TypeDoc
Destroys the GPUBuffer. Note: It is valid to destroy a buffer multiple times. Note: Since no further operations can be enqueued using this buffer, implementations can free resource allocations, including mapped memory that was just unmapped.