interface.RenderModuleContext
API > RenderModuleContext
Interface: RenderModuleContext
A render module's context for a specific render context.
Remarks
This object should contain all GPU/render context specific resources and handle actual updates and rendering.
Properties
module
readonly
module:RenderModule
Associated render module.
Source
@novorender/core3d/modules/index.ts:23
pick
pick?: (
state
) =>void
Render into pick buffers with module specific data.
Parameters
Parameter | Type | Description |
---|---|---|
state | DerivedRenderState | The current frame render state. |
Returns
void
Source
@novorender/core3d/modules/index.ts:41
prepass
prepass?: (
state
) =>void
Do a preliminary render pass to fill in Z-buffer for GPUs where this is beneficial.
Parameters
Parameter | Type | Description |
---|---|---|
state | DerivedRenderState | The current frame render state. |
Returns
void
Source
@novorender/core3d/modules/index.ts:35
Methods
contextLost
contextLost():
void
Handle loss of underlying WebGLContext, e.g. by cancelling pending downloads.
Returns
void
Source
@novorender/core3d/modules/index.ts:50
dispose
dispose():
void
Dispose of all GPU resources.
Returns
void
Source
@novorender/core3d/modules/index.ts:53
render
render(
state
):void
Render into color and depth buffer.
Parameters
Parameter | Type | Description |
---|---|---|
state | DerivedRenderState | The current frame render state. |
Returns
void
Source
@novorender/core3d/modules/index.ts:47
update
update(
state
):void
Update module specific GPU state, such as uniform buffers.
Parameters
Parameter | Type | Description |
---|---|---|
state | DerivedRenderState | The current frame render state. |
Returns
void