AdvancedOptional ReadonlybitThe RenderPassBit of the meshes the pass draws; give RenderPassBit.NONE on a pass that draws none
Optional ReadonlycameraCamera this pass draws from, or null or absent for the view's own
A camera with a render texture draws into that texture. Any other camera draws into its frame
within the view: while render runs on a pass with attachments, the GPU viewport and
session.activeViewport cover only that frame.
Optional ReadonlydescriptionWhat the pass adds to the frame, shown by debug tools
ReadonlynameNames the pass in errors and debug tools
OptionalconditionReturn false to skip the pass this frame, prepare included, and any pass that only feeds it
A later pass that reads what this one writes isn't skipped with it, and sees whatever the texture last held. For a texture the graph allocates, that can be another pass's leftovers; to keep a result across skipped frames, write it into one you import with RenderGraph#importColor.
The frame's render session.
Whether the pass runs this frame.
OptionaldestroyReleases the pass; the graph calls it once, when it is destroyed
OptionalprepareRuns on each frame the pass runs, before any pass renders, for uploads and compute work such as culling; the cameras are already updated
Draws the pass on each frame it runs, after the graph binds the textures it samples and any target it declared
Declares the textures the pass reads and writes; runs once, when the pass is added
Records the declarations for this pass.
OptionalunloadFrees GPU memory the pass can rebuild, such as the shadow pass's map; RenderGraph#unload calls it
It can run any number of times and the pass keeps rendering, so whatever it frees must come back on the next frame that needs it.
What RenderGraph#addPass takes: a RenderPass, or a plain object with
name,setupandrender