Capítulo 261 de 859
Abstract base class for all post processing passes.
This module is only relevant for post processing with WebGLRenderer.
true, the pass clears its buffer before renderingtrue, the pass is processed by the composer.true, the pass indicates to swap read and write buffer after rendering.true, the result of the pass is rendered to screen. The last pass in the composers pass chain gets automatically rendered to sc…import { Pass } from 'three/addons/postprocessing/Pass.js';
Constructor
| Signature |
|---|
new Pass() (abstract) |
Properties
| Property | Description |
|---|---|
.clear : boolean | If set to true, the pass clears its buffer before rendering |
.enabled : boolean | If set to true, the pass is processed by the composer. |
.isPass : boolean (readonly) | This flag can be used for type testing. |
.needsSwap : boolean | If set to true, the pass indicates to swap read and write buffer after rendering. |
.renderToScreen : boolean | If set to true, the result of the pass is rendered to screen. The last pass in the composers pass chain gets automatically rendered to screen, no matter how this property is configured. |
Methods
| Method | Description |
|---|---|
.dispose() (abstract) | Frees the GPU-related resources allocated by this instance. Call this method whenever the pass is no longer used in your app. |
.render( renderer : WebGLRenderer, writeBuffer : WebGLRenderTarget, readBuffer : WebGLRenderTarget, deltaTime : number, maskActive : boolean ) (abstract) | This method holds the render logic of a pass. It must be implemented in all derived classes. |
.setSize( width : number, height : number ) (abstract) | Sets the size of the pass. |