Skip to content

rawFilter

rawFilter(filter, options?): EffectFactory

Defined in: renderer/src/effects/rawFilter.ts:36

Wrap a user-supplied pixi Filter so it can be attached through the addEffect API and managed by the same handle interface as built-in effect presets. The escape hatch for custom shaders or any pixi-filters import the engine doesn’t expose a typed wrapper for.

import { BlurFilter } from "pixi.js";
sprite.addEffect(rawFilter(new BlurFilter({ strength: 8 }), {
intensity: {
get: () => filter.strength,
set: (v) => { filter.strength = v * 8; },
},
}));

Without the intensity option, fadeIn / fadeOut will return an already-completed Process and warn once per session — the system can’t guess which uniform represents the effect’s “strength.”

Filter

RawFilterOptions

EffectFactory