Represents a render pass for producing a toon outline effect on compatible objects.
Only 3D objects with materials of type MeshToonMaterial and MeshToonNodeMaterial
will receive the outline.
const postProcessing = new RenderPipeline( renderer );
const scenePass = toonOutlinePass( scene, camera );
postProcessing.outputNode = scenePass;
export {}Constructor
new ToonOutlinePassNode(scene, camera, colorNode, thicknessNode, alphaNode)| Parameter | Type | Default Value |
|---|---|---|
| scene | Scene | — |
| camera | Camera | — |
| colorNode | Node | — |
| thicknessNode | Node | — |
| alphaNode | Node | — |
Constructs a new outline pass node.
| Accessor | Type | |
|---|---|---|
| get type | string | |
Properties
| Property | Type | Default Value | |
|---|---|---|---|
| colorNode | Node | — | |
| thicknessNode | Node | — | |
| alphaNode | Node | — | |
| _materialCache | WeakMap<Material, NodeMaterial> | — | |
| Method | Type | |
|---|---|---|
| updateBefore | (frame: any) => void | |
| _createMaterial | () => NodeMaterial | |
| _getOutlineMaterial | (originalMaterial: any) => NodeMaterial | |
Extends
PassNodeTSL function for creating a toon outline pass node.
| Parameter | Type | Default Value |
|---|---|---|
| scene | Scene | — |
| camera | Camera | — |
| color? | Color | new Color( 0, 0, 0 ) |
| thickness? | number | 0.003 |
| alpha? | number | 1 |
Returns
ToonOutlinePassNode