threejs-errors-rendering
Installation
SKILL.md
threejs-errors-rendering
Debugging Workflow Checklist
When a Three.js scene does not render correctly, ALWAYS follow this sequence:
- Open the browser console -- check for WebGL errors or Three.js warnings
- Verify the renderer has a non-zero size (
renderer.getSize(new THREE.Vector2())) - Confirm the canvas is in the DOM and visible (not
display: none) - Check that
renderer.render(scene, camera)is called (in a loop or at least once) - Verify the camera is looking at the scene (position, target, near/far)
- Confirm at least one light exists for lit materials
- Check material
side,visible,opacity, andtransparentproperties - Verify object
visible,layers, andfrustumCulledproperties - Inspect color space settings on renderer and textures
Symptom 1: Black Screen (Nothing Visible)
Related skills