Pixelation Effect
Updated
Draws the image in large square pixels, like a retro game.
- Type
comp-pixelation-effect- Script class
PixelationEffectComponent- Per entity
- One
- Version
- 1.3.0
Read about it in Stylize effects: what it does, how to use it from a script, and examples.
Properties
Section titled “Properties”The props the runtime declares for this component, with their defaults and accepted ranges.
| Prop | Default | Range |
|---|---|---|
granularity |
6 |
0 ≤ x ≤ 128 |
Live example
Section titled “Live example”Run it in the browser, read its scripts, and download it as an XR Creator project.
Live example
Switch a retro screen on and offPixelation, Scanline and Noise effects on the camera make the scene look like an old monitor; pressing Space tweens all three in or out together.
Click the scene, then press Space to fade between the retro look and the clean picture. Drag to orbit the camera, scroll to zoom.
From a script
Section titled “From a script”#pragma lifecycle(startup)
function startup() { const component = self.parent.getComponent(PixelationEffectComponent); if (component) log(component.props);}