MCPInstall

threejs-lights

three.js lighting: AmbientLight, HemisphereLight, DirectionalLight, PointLight, SpotLight, RectAreaLight, LightProbe, IESSpotLight, ProjectorLight, shadow subtypes, and addon helpers such as RectAreaLightUniformsLib, RectAreaLightTexturesLib, LightProbeGenerator, TiledLighting. Use when configuring direct/indirect light, shadows, probes, or area lights; for IES file loading use threejs-loaders; for node-based light graphs use threejs-node-tsl; for debug helpers use threejs-helpers.

Installs
411
Last 24h
—
Trending rank
—
Security
Not audited

Install

Works with every agent the skills CLI supports.

npx skills add https://github.com/full-stack-skills/threejs-skills --skill threejs-lights
  1. 01

    Install

    Run the command in your project. The CLI asks which agents to install for.

  2. 02

    Describe the task

    Ask your agent for something this skill covers. It loads threejs-lights automatically when relevant.

  3. 03

    Review the result

    The agent follows the SKILL.md steps, scripts and references bundled with the skill.

SKILL.md

The instructions your agent reads when the skill is triggered.

When to use this skill

ALWAYS use this skill when the user mentions:

  • Enabling castShadow / receiveShadow, shadow map size, bias, normal bias, camera frusta for shadow casters
  • Physical lights: intensity, distance/decay, angle/penumbra for spots, rect area setup
  • LightProbe for irradiance-style probes; IESSpotLight with IES data

IMPORTANT: lights vs loaders vs node-tsl

TopicSkill
Light classes and shadowsthreejs-lights
Loading IES/HDR filesthreejs-loaders
LightNode / TSL lightingthreejs-node-tsl

Trigger phrases include:

  • "DirectionalLight", "SpotLight", "RectAreaLight", "castShadow", "shadow map"
  • "阴影", "点光源", "面光源", "LightProbe"

How to use this skill

  1. Base recipe: ambient/hemisphere fill + directional sun + local points/spots.
  2. Shadows: enable on renderer, mark casters/receivers, tune map size vs performance, adjust bias to remove acne/peter-panning.
  3. RectArea: initialize addon libs per docs page before using light type.
  4. Probes: place probes; generate data via addon generator when applicable; relate to materials env reflections (threejs-materials, threejs-textures).
  5. IES: load profile via loader skill, attach to IESSpotLight per docs.
  6. Performance: limit shadow-casting lights; use layers (threejs-objects) to exclude objects.

See examples/workflow-directional-shadow.md.

Doc map (official)

Scope

  • In scope: Core lights, shadow maps, probes, listed addons for rect area and probe generation.
  • Out of scope: CSM deep theory (see addon Csm docs if user names it); baked lightmaps in DCC.

Common pitfalls and best practices

  • Shadow map resolution must match scene scale—tiny shadows on huge worlds look blocky.
  • Point light shadows are six-face expensive—use wisely.
  • RectAreaLight without required libs yields black or wrong shading—verify init.
  • Mismatched physical units (intensity vs exposure) with threejs-renderers tone mapping causes blown or dim scenes.
  • Shadow bias / normalBias trade-offs: acne vs peter-paning—tune with helper frusta (threejs-helpers).

Documentation and version

Light and shadow classes live under Lights in three.js docs. RectAreaLight and probe addons depend on extra init from Addons → Lights; IES profiles require threejs-loaders for file fetch before the light API is usable.

Agent response checklist

When answering under this skill, prefer responses that:

  1. Link the concrete light type (DirectionalLight, SpotLight, …) and shadow pages when shadows are on.
  2. Separate IES loading to threejs-loaders and LightNode topics to threejs-node-tsl.
  3. Give practical shadow map size / bias guidance with threejs-helpers for frustum visualization.
  4. Mention renderer.shadowMap.enabled alongside light castShadow (see threejs-renderers).
  5. Note performance cost of multiple shadow-casting lights.

References

Keywords

English: lights, shadows, directional, spotlight, rectarea, lightprobe, three.js

中文: 灯光、阴影、平行光、聚光灯、面光源、LightProbe、three.js

FAQ

What does the threejs-lights skill do?

three.js lighting: AmbientLight, HemisphereLight, DirectionalLight, PointLight, SpotLight, RectAreaLight, LightProbe, IESSpotLight, ProjectorLight, shadow subtypes, and addon helpers such as RectAreaLightUniformsLib, RectAreaLightTexturesLib, LightProbeGenerator, TiledLighting. Use when configuring direct/indirect light, shadows, probes, or area lights; for IES file loading use threejs-loaders; for node-based light graphs use threejs-node-tsl; for debug helpers use threejs-helpers.

How do I install threejs-lights?

Run npx skills add https://github.com/full-stack-skills/threejs-skills --skill threejs-lights in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/threejs-lights/ (personal) or .claude/skills/threejs-lights/ (project).

Which AI agents can use threejs-lights?

Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.

Is threejs-lights safe to install?

No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.

Who maintains threejs-lights?

It is published by full-stack-skills in full-stack-skills/threejs-skills. It has 411 recorded installs.

More from full-stack-skills/threejs-skills

View all →

threejs-animation

full-stack-skills/threejs-skills

three.js keyframe animation system: AnimationMixer, AnimationClip, AnimationAction, KeyframeTrack variants, PropertyBinding, PropertyMixer, AnimationObjectGroup, AnimationUtils; mixing and crossfading clips, loop modes, timeScale, weight; addon AnimationClipCreator and CCDIKSolver for procedural rigs. Use when playing glTF clips, blending actions, or authoring procedural tracks; for skin deformation rigging on meshes see threejs-objects; for math interpolants without clips see threejs-math only when not tied to AnimationMixer.

Frontend & Design415 installs

threejs-camera

full-stack-skills/threejs-skills

three.js cameras: Camera base, PerspectiveCamera, OrthographicCamera, CubeCamera, ArrayCamera, StereoCamera; projection matrices, aspect, FOV, orthographic frustum sizes, near/far planes, and dynamic environment maps with CubeCamera. Use when placing views, rendering reflections, or multi-view splits; for XR projections and eye matrices use threejs-webxr; for post pass camera tricks use threejs-postprocessing alongside threejs-renderers.

410 installs

threejs-postprocessing

full-stack-skills/threejs-skills

Addon screen-space post-processing for three.js using EffectComposer, Pass base class, RenderPass, and stock passes such as UnrealBloomPass, SSAOPass, SSRPass, BokehPass, OutlinePass, FXAAPass/SMAAPass, TAARenderPass, and ShaderPass; references the Shaders addon group for underlying shader modules; contrasts with core PostProcessing class used in node/WebGPU stacks (see threejs-node-tsl and threejs-renderers). Use when building composer chains—not for basic renderer tone mapping alone (threejs-renderers).

Business & Finance404 installs

threejs-loaders

full-stack-skills/threejs-skills

three.js asset I/O using LoadingManager, Cache, FileLoader, image and texture loaders, GLTFLoader with DRACOLoader and KTX2Loader, and common format loaders under Addons; symmetric exporters such as GLTFExporter and texture/buffer exporters. Use when loading or exporting models, HDR, LUT, fonts, or compressed textures; for runtime Texture object parameters after load use threejs-textures; for scene graph placement use threejs-objects.

Media & Creative399 installs

threejs-objects

full-stack-skills/threejs-skills

three.js scene graph objects: Object3D transforms and hierarchy, Group, Mesh, InstancedMesh, SkinnedMesh, BatchedMesh, LOD, Line/LineLoop/LineSegments, Points, Sprite, Bone, Skeleton, ClippingGroup; interaction via Raycaster, Layers masks, and EventDispatcher patterns. Merges the former interaction scope—use for picking and layers; for pure vector math without scene graph use threejs-math; for playing skeletal clips use threejs-animation; for frustum culling internals see camera docs.

threejs-materials

full-stack-skills/threejs-skills

Open the skill to read its SKILL.md instructions.

394 installs

Popular code quality & workflow skills

View category →

grill-me

mattpocock/skills

A relentless interview to sharpen a plan or design.

Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.

handoff

mattpocock/skills

Compact the current conversation into a handoff document for another agent to pick up.

domain-modeling

mattpocock/skills

Build and sharpen a project's domain model. Use when discussing codebase terminology, writing or editing a GLOSSARY.md, or recording or editing an ADR.

codebase-design

mattpocock/skills

Shared vocabulary for designing deep modules. Use when the user wants to design or improve a module's interface, find deepening opportunities, decide where a seam goes, make code more testable or AI-navigable, or when another skill needs the deep-module vocabulary.

diagnosing-bugs

mattpocock/skills

Diagnosis loop for hard bugs and performance regressions. Use when the user says "diagnose"/"debug this", or reports something broken/throwing/failing/slow.