General Effects
Manages various standard effects provided by RedGPU, such as radial blur and grayscale.
[Learning Guide]
Technically, tone mapping is executed at the very first stage of the overall post-processing, but in this chapter, we first cover General Effects where visual changes can be experienced most intuitively.
1. Usage (addEffect)
After creating an effect object, register it through view.postEffectManager.addEffect(). A pipeline chain is formed in the order of registration.
const radialBlur = new RedGPU.PostEffect.RadialBlur(redGPUContext);
view.postEffectManager.addEffect(radialBlur);2. Key Effect Examples
2.1 Radial Blur
Creates a sense of speed or concentration effects that spread outward from a center point.
2.2 Grayscale
Converts the image to black and white to create a classic atmosphere.
3. Full Support List
Full list of all general effects provided by RedGPU. All effects are located under the RedGPU.PostEffect namespace.
| Category | Class Name | Description |
|---|---|---|
| Blur | Blur, GaussianBlur | Gaussian blur (Most common blur effect) |
BlurX, BlurY | Unidirectional (horizontal/vertical) blur | |
DirectionalBlur | Blur effect in a specified angle direction | |
RadialBlur | Blur effect spreading outward from the center in a circle | |
ZoomBlur | Blur effect expanding outward from the center | |
| Adjustments | BrightnessContrast | Brightness and contrast adjustment |
HueSaturation | Hue and saturation adjustment | |
ColorBalance | Color balance (midtones, shadows, highlights) adjustment | |
ColorTemperatureTint | Color temperature and tint adjustment | |
Vibrance | Vibrance (adjust mainly unsaturated parts) | |
Grayscale | Converts image to black and white | |
Invert | Color inversion | |
Threshold | Binarization based on a threshold | |
| Lens | OldBloom | Classic light bleeding effect |
DOF | Depth of field (blur areas out of focus) | |
Vignetting | Effect of darkening the outer edges of the screen | |
ChromaticAberration | Recreates lens chromatic aberration | |
LensDistortion | Lens distortion effect | |
| Atmospheric | Fog | Distance-based fog effect |
HeightFog | Height-based fog effect | |
| Visual / Utility | FilmGrain | Film noise (grain) effect |
Sharpen | Sharpening | |
Convolution | Kernel-based filter (supports Sharpen, Edge, Emboss, etc.) |
[Check Live]
All the effects above can be checked in real-time demos in the PostEffect category of the RedGPU Official Examples Page.
Key Summary
- You can layer effects in any order using
addEffect(). - All effect objects require
redGPUContextupon creation. - Actual rendering is performed immediately after the tone mapping stage.