Abstract Class: RenderPass
Defined in: modules/core/src/adapter/resources/render-pass.ts:102
A RenderPass instance is a required parameter to all draw calls.
It holds a combination of
- render targets (specified via a framebuffer)
- clear colors, read/write, discard information for the framebuffer attachments
- a couple of mutable parameters ()
Extends
Extended by
Constructors
Constructor
new RenderPass(
device,props,defaultProps?):RenderPass
Defined in: modules/core/src/adapter/resources/render-pass.ts:114
Parameters
device
props
defaultProps?
Required<RenderPassProps> = RenderPass.defaultProps
Returns
RenderPass
Overrides
Properties
destroyed
destroyed:
boolean=false
Defined in: modules/core/src/adapter/resources/resource.ts:131
Whether this resource has been destroyed
Inherited from
device
abstractreadonlydevice:Device
Defined in: modules/core/src/adapter/resources/resource.ts:124
The device that this resource is associated with
Inherited from
handle
abstractreadonlyhandle:unknown
Defined in: modules/core/src/adapter/resources/resource.ts:126
The handle for the underlying resource, e.g. WebGL object or WebGPU handle
Inherited from
id
id:
string
Defined in: modules/core/src/adapter/resources/resource.ts:118
props.id, for debugging.
Inherited from
props
readonlyprops:Required<Props>
Defined in: modules/core/src/adapter/resources/resource.ts:120
The props that this resource was created with
Inherited from
userData
readonlyuserData:Record<string,unknown> ={}
Defined in: modules/core/src/adapter/resources/resource.ts:122
User data object, reserved for the application
Inherited from
defaultClearColor
staticdefaultClearColor: [number,number,number,number]
Defined in: modules/core/src/adapter/resources/render-pass.ts:104
TODO - should be [0, 0, 0, 0], update once deck.gl tests run clean
defaultClearDepth
staticdefaultClearDepth:number=1
Defined in: modules/core/src/adapter/resources/render-pass.ts:106
Depth 1.0 represents the far plance
defaultClearStencil
staticdefaultClearStencil:number=0
Defined in: modules/core/src/adapter/resources/render-pass.ts:108
Clears all stencil bits
defaultProps
staticdefaultProps:Required<RenderPassProps>
Defined in: modules/core/src/adapter/resources/render-pass.ts:177
Default properties for RenderPass
Overrides
Accessors
[toStringTag]
Get Signature
get [toStringTag]():
string
Defined in: modules/core/src/adapter/resources/render-pass.ts:110
Returns
string
Overrides
isHandleBorrowed
Get Signature
get isHandleBorrowed():
boolean
Defined in: modules/core/src/adapter/resources/resource.ts:147
Whether luma.gl may only reference the opaque externally owned resource handle.
Returns
boolean
Inherited from
ownsHandle
Get Signature
get ownsHandle():
boolean
Defined in: modules/core/src/adapter/resources/resource.ts:140
Whether luma.gl created and owns the underlying resource handle.
Returns
boolean
Inherited from
Methods
attachResource()
attachResource(
resource):void
Defined in: modules/core/src/adapter/resources/resource.ts:200
Attaches a resource. Attached resources are auto destroyed when this resource is destroyed Called automatically when sub resources are auto created but can be called by application
Parameters
resource
Returns
void
Inherited from
beginOcclusionQuery()
abstractbeginOcclusionQuery(queryIndex):void
Defined in: modules/core/src/adapter/resources/render-pass.ts:161
Being an occlusion query. Value will be stored in the occlusionQuerySet at the index. Occlusion queries cannot be nested.
Parameters
queryIndex
number
Returns
void
delete()
delete():
this
Defined in: modules/core/src/adapter/resources/resource.ts:181
Returns
this
Deprecated
Use destroy()
Inherited from
destroy()
destroy():
void
Defined in: modules/core/src/adapter/resources/resource.ts:173
destroy can be called on any resource to release it before it is garbage collected.
Returns
void
Inherited from
destroyAttachedResource()
destroyAttachedResource(
resource):void
Defined in: modules/core/src/adapter/resources/resource.ts:214
Destroys a resource (only if owned), and removes from the owned (auto-destroy) list for this resource.
Parameters
resource
Returns
void
Inherited from
Resource.destroyAttachedResource
destroyAttachedResources()
destroyAttachedResources():
void
Defined in: modules/core/src/adapter/resources/resource.ts:221
Destroy all owned resources. Make sure the resources are no longer needed before calling.
Returns
void
Inherited from
Resource.destroyAttachedResources
detachResource()
detachResource(
resource):void
Defined in: modules/core/src/adapter/resources/resource.ts:207
Detach an attached resource. The resource will no longer be auto-destroyed when this resource is destroyed.
Parameters
resource
Returns
void
Inherited from
draw()
abstractdraw(options):boolean
Defined in: modules/core/src/adapter/resources/render-pass.ts:145
Issues a draw using the currently selected pipeline, bindings, and vertex array.
Parameters
options
Returns
boolean
drawIndexedIndirect()
abstractdrawIndexedIndirect(indirectBuffer,indirectByteOffset?):void
Defined in: modules/core/src/adapter/resources/render-pass.ts:151
Issues an indexed draw using five 32-bit arguments stored in an indirect buffer.
Parameters
indirectBuffer
indirectByteOffset?
number
Returns
void
drawIndirect()
abstractdrawIndirect(indirectBuffer,indirectByteOffset?):void
Defined in: modules/core/src/adapter/resources/render-pass.ts:148
Issues a non-indexed draw using four uint32 arguments stored in an indirect buffer.
Parameters
indirectBuffer
indirectByteOffset?
number
Returns
void
end()
abstractend():void
Defined in: modules/core/src/adapter/resources/render-pass.ts:124
Call when rendering is done in this pass.
Returns
void
endOcclusionQuery()
abstractendOcclusionQuery():void
Defined in: modules/core/src/adapter/resources/render-pass.ts:163
End an occlusion query. Stores result in the index specified in beginOcclusionQuery.
Returns
void
executeBundles()
abstractexecuteBundles(bundles):void
Defined in: modules/core/src/adapter/resources/render-pass.ts:158
Replays reusable draw commands recorded by one or more render bundle encoders.
Parameters
bundles
Iterable<RenderBundle>
Bundles whose attachment formats and sample count are compatible with this pass.
Returns
void
Throws
On backends other than WebGPU.
getProps()
getProps():
object
Defined in: modules/core/src/adapter/resources/resource.ts:190
Combines a map of user props and default props, only including props from defaultProps
Returns
object
returns a map of overridden default props
Inherited from
insertDebugMarker()
abstractinsertDebugMarker(markerLabel):void
Defined in: modules/core/src/adapter/resources/render-pass.ts:170
Marks a point in a stream of commands with a label
Parameters
markerLabel
string
Returns
void
popDebugGroup()
abstractpopDebugGroup():void
Defined in: modules/core/src/adapter/resources/render-pass.ts:168
Ends the labeled debug group most recently started by pushDebugGroup()
Returns
void
pushDebugGroup()
abstractpushDebugGroup(groupLabel):void
Defined in: modules/core/src/adapter/resources/render-pass.ts:166
Begins a labeled debug group containing subsequent commands
Parameters
groupLabel
string
Returns
void
setBindings()
abstractsetBindings(bindings,options?):void
Defined in: modules/core/src/adapter/resources/render-pass.ts:136
Replaces the complete binding set used by subsequent draw commands. A pipeline must be selected first so bindings can be resolved against its shader layout.
Parameters
bindings
Bindings | Partial<Record<number, Bindings>>
options?
Returns
void
setParameters()
abstractsetParameters(parameters):void
Defined in: modules/core/src/adapter/resources/render-pass.ts:127
A few parameters can be changed at any time (viewport, scissorRect, blendColor, stencilReference)
Parameters
parameters
Returns
void
setPipeline()
abstractsetPipeline(pipeline):void
Defined in: modules/core/src/adapter/resources/render-pass.ts:130
Selects the pipeline used by subsequent binding and draw commands.
Parameters
pipeline
Returns
void
setVertexArray()
abstractsetVertexArray(vertexArray):void
Defined in: modules/core/src/adapter/resources/render-pass.ts:142
Selects the vertex array used by subsequent draw commands.
Parameters
vertexArray
Returns
void
toJSON()
toJSON():
string
Defined in: modules/core/src/adapter/resources/resource.ts:113
Compact serialization for assertion diffs and structured debug logs.
Returns
string
Inherited from
toString()
toString():
string
Defined in: modules/core/src/adapter/resources/resource.ts:108
Returns
string