API reference

Every public class, method, and event in @codexo/exojs. Generated from source.

C

classFilterPass

@codexo/exojs / rendering / stable

Runs a Filter or a chain of them from a source texture into a destination, as one pass inside a RenderPipeline. ```ts pipeline .addPass(new RenderNodePass(world, { target: sceneRt, clear: Color.black })) .addPass(new FilterPass(sceneRt, [bloom, grade])); ``` Intermediates between chain stages are borrowed from the backend's render-texture pool for the length of one execute and returned on every path, including when a filter throws. They are sized to the DESTINATION, so a chain neither grows nor shrinks the image: an effect that reaches outside its input (a blur, a glow) is clipped at the destination's edge, which is what a full-frame post-process wants and the one thing a filter at a node does differently - there the capture domain grows to the effect's declared reach, because a node has room around it and a frame does not. An empty chain is a blit, which is the useful degenerate case: it is how a pipeline shows an off-screen target on the canvas. The filters are caller-owned - a filter may be shared with a node or another pass - so destroy releases only what this pass allocated.

3
props
3
methods
0
events
Import
import { FilterPass } from '@codexo/exojs'

Runs a Filter or a chain of them from a source texture into a destination, as one pass inside a RenderPipeline.

```ts pipeline .addPass(new RenderNodePass(world, { target: sceneRt, clear: Color.black })) .addPass(new FilterPass(sceneRt, [bloom, grade])); ```

Intermediates between chain stages are borrowed from the backend's render-texture pool for the length of one execute and returned on every path, including when a filter throws. They are sized to the DESTINATION, so a chain neither grows nor shrinks the image: an effect that reaches outside its input (a blur, a glow) is clipped at the destination's edge, which is what a full-frame post-process wants and the one thing a filter at a node does differently - there the capture domain grows to the effect's declared reach, because a node has room around it and a frame does not.

An empty chain is a blit, which is the useful degenerate case: it is how a pipeline shows an off-screen target on the canvas.

The filters are caller-owned - a filter may be shared with a node or another pass - so destroy releases only what this pass allocated.

Constructors1
Methods3
destroy(): void
Release resources this pass allocated internally. No-op by default; idempotent. Never frees injected scene nodes or caller-provided RenderTextures - those are owned by the caller / scene.
Run this pass against context. The active render target is the canvas unless a parent redirected it. Called directly, this runs **regardless of enabled** - enabled is evaluated by the containing RenderPipeline, not self-checked here. Subclasses must not begin execute with if (!this.enabled).
resize(_width: number, _height: number): void
React to a surface / target size change. No-op by default; size-dependent passes (effects with scratch targets) override. Called by RenderPipeline.resize, which the caller wires to app.onResize.
Properties3
enabled: boolean
When false, the containing RenderPipeline skips this pass during execute. Default true. Evaluated by the parent - a direct execute call runs the pass regardless.
label: string
Debug label (inspector / logging). Defaults to the constructor name. Display only - not an identity.
Source