Glow and depth for 3D scenes
Ask Claude for bloom, depth of field or colour grading on a Three.js scene, in the right pass order.
See it work
You give it
Use threejs-postprocessing. Our Jodhpur lantern workshop's three.js (r186) viewer shows a pierced brass lantern with an emissive mesh, bulb, inside. Only the light through the holes should glow, but the lantern and the beige background glow too, all washed out, and edges are jagged despite antialias: true. My code:
const composer = new EffectComposer(renderer);
composer.addPass(new RenderPass(scene, camera));
composer.addPass(new UnrealBloomPass(new THREE.Vector2(innerWidth/2, innerHeight/2), 1.5, 0.4, 0.2));
composer.addPass(new ShaderPass(FXAAShader));
composer.addPass(new ShaderPass(GammaCorrectionShader));
function animate() { requestAnimationFrame(animate); composer.render(); }
You get back
Every symptom you describe comes from those six lines. I can only see this code, not the scene or a render, so the fixes below are about the chain itself.
What's going wrong
Line · What happens · Fix
UnrealBloomPass(..., 1.5, 0.4, 0.2) · The last number is the threshold: anything brighter than 0.2 glows. Your beige background and the lit brass are far brighter than that, so the whole frame blooms and washes out. · Bloom only the bulb, with a layer (below). Then nothing else can glow, whatever its brightness.
new THREE.Vector2(innerWidth/2, innerHeight/2) · The half-size trick does nothing: addPass resizes the pass to the composer's size straight away. · Pass the full size and let the composer size it.
new ShaderPass(FXAAShader) before the gamma pass · FXAA needs sRGB input, and here it gets linear colour. Wrapped in a ShaderPass, its resolution uniform never gets your canvas size, so it's off, worst on high-DPI screens. · Not needed at all once the composer has MSAA (below). If you ever want FXAA, use FXAAPass after OutputPass.
new ShaderPass(GammaCorrectionShader) · It only applies the sRGB curve. It skips the renderer's tone mapping and exposure, so bright areas can clip. · new OutputPass() as the last pass.
Jagged edges with antialias: true · The composer's buffers aren't multisampled; the renderer's antialias never reaches them. · Give the composer its own render target with samples: 4.
requestAnimationFrame(animate) · Works, but the three.js docs advise setAnimationLoop instead, and it's what WebXR needs if you ever add it. · renderer.setAnimationLoop(animate)
First part of a run in Claude (Opus 5.5), Nov 2026
What it does
- Sets up the effect chain in the right order.
- Makes only chosen objects glow.
- Covers the newer WebGPU set-up too.
What's inside
threejs-postprocessing/CREDITS.mdthreejs-postprocessing/LICENSEthreejs-postprocessing/SKILL.md
How you use it
- Get the skill: one zip file. It comes with every paid plan.
- Add it to Claude. In Claude, open Customize (Plugins on newer screens), then Skills. Press +, then Create skill, then Upload a skill. In Claude Code, unzip it into ~/.claude/skills/ instead.
- Start a new chat and tell Claude what you need, the way the example above does. The skill takes it from there.
- Then ask for the work. Claude reaches for the skill when it fits, or name it: "use threejs-postprocessing".
Get this skill with a paid plan
The download comes with every paid plan, along with all 204 Claude skills and the rest of the AI toolkit. “Sites that don't look templated” in this folder is free, so you can try one first.