Advanced
The renderer the graph draws with.
What the view hands its graph builder; see DefaultGraph3DOptions.
The compiled graph and the DefaultGraph3DHandles its passes share.
The compiled render graph
Textures the default passes share
new View3D({
graph: (renderer, options) => {
const { graph, handles } = createDefaultGraph3D(renderer, options);
graph.addPass(new MyHeatHazePass({ renderer, opaqueColorHandle: handles.opaqueColor }));
return graph;
},
});
If a pass that isn't a PostEffect claims the 'beforeToneMapping' or
'afterToneMapping' stage.
Builds the render graph a View3D uses unless its
graphoption supplies oneStart from it in a custom
graphbuilder to add passes the Pass3D stages can't express. The passes run in this order, with each user pass built at its PassStage:'beforeOpaque'user passes.'afterOpaque'user passes.'afterTransparent'user passes.'beforeToneMapping'effects, in array order, then the tone curve, then the'afterToneMapping'effects. Unless the tone mapping is'custom', an output pass applies the curve after a'beforeToneMapping'effect, and the scene draw applies it otherwise.In composite mode the scene draws into textures at View3D#resolution, which the graph's other textures inherit unless an effect sets its own. The scene's textures are multisampled when the canvas has
antialias, unless a scene output's format can't be (see SceneOutput). Each effect reads what the one before it wrote, and the last step stretches the image onto the view's rect.With a
'beforeToneMapping'effect enabled, the scene colour and every colour texture made without a format arergba16float, so brightness above 1 reaches each of those effects. Unless the tone mapping is'custom', the'afterToneMapping'effects readrgba8unorm. An effect whoseinputMipsis set gets an input with mipmaps.The graph comes back compiled, so authoring mistakes throw here rather than on the first frame.