Skip to main content
Glama
threejs-devtools-mcp

threejs-devtools-mcp

by DmitriyGolub

set_shadow

Idempotent

Adjust shadow casting and receiving on Three.js objects, and tune light bias, map size, and shadow camera settings in the live browser preview. Changes are pending and undoable.

Instructions

[LIVE PREVIEW] Changes the scene in the browser only — NOT saved to source code, lost on reload. Recorded in pending_changes (→ code edits) and undoable with revert_changes. Change shadow casting/receiving on any object, and bias/mapSize/shadow camera on lights.

Input Schema

NameRequiredDescriptionDefault
biasNoLight only, e.g. -0.0001
nameNoObject or light name
uuidNoObject or light UUID
radiusNoBlur radius (light only)
mapSizeNo[width, height] shadow map resolution
cameraFarNo
cameraTopNoDirectionalLight
cameraLeftNoDirectionalLight
cameraNearNo
castShadowNo
normalBiasNoLight only
blurSamplesNoVSM blur samples (light only)
cameraRightNoDirectionalLight
cameraBottomNoDirectionalLight
receiveShadowNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed15 schema fields changedv0.5.0
    • removedInput schema / additionalProperties
      Removed value: -false
    • changedInput schema / properties / bias / description
      Previous value: -"Shadow bias (light only, e.g. -0.0001)"New value: +"Light only, e.g. -0.0001"
    • changedInput schema / properties / blurSamples / description
      Previous value: -"Shadow blur samples (light only)"New value: +"VSM blur samples (light only)"
    • changedInput schema / properties / cameraBottom / description
      Previous value: -"Shadow camera bottom (DirectionalLight)"New value: +"DirectionalLight"
    • removedInput schema / properties / cameraFar / description
      Removed value: -"Shadow camera far plane"
    • changedInput schema / properties / cameraLeft / description
      Previous value: -"Shadow camera left (DirectionalLight)"New value: +"DirectionalLight"
    • removedInput schema / properties / cameraNear / description
      Removed value: -"Shadow camera near plane"
    • changedInput schema / properties / cameraRight / description
      Previous value: -"Shadow camera right (DirectionalLight)"New value: +"DirectionalLight"
    • changedInput schema / properties / cameraTop / description
      Previous value: -"Shadow camera top (DirectionalLight)"New value: +"DirectionalLight"
    • removedInput schema / properties / castShadow / description
      Removed value: -"Enable/disable shadow casting"
    • changedInput schema / properties / name / description
      Previous value: -"Object/light name"New value: +"Object or light name"
    • changedInput schema / properties / normalBias / description
      Previous value: -"Shadow normal bias (light only)"New value: +"Light only"
    • changedInput schema / properties / radius / description
      Previous value: -"Shadow blur radius (light only)"New value: +"Blur radius (light only)"
    • removedInput schema / properties / receiveShadow / description
      Removed value: -"Enable/disable shadow receiving"
    • changedInput schema / properties / uuid / description
      Previous value: -"Object/light UUID"New value: +"Object or light UUID"
  2. First observedv0.4.1

TDQS

A4/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Goes well beyond the annotations (readOnlyHint=false, destructiveHint=false, idempotentHint=true) by disclosing that edits are browser-only, never written to source, lost on reload, tracked in pending_changes, and undoable via revert_changes. That non-persistence/undo contract is exactly the context the annotations cannot convey.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two dense sentences, with the critical '[LIVE PREVIEW]' caveat front-loaded before the capability statement. No filler, though the pending_changes/revert_changes parenthetical makes the first sentence slightly packed.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers ephemerality, undo path, and which parameter families target objects vs lights for a 15-parameter mutation tool with no output schema. It leaves a gap on target identification (0 required params, name/uuid precedence) but is otherwise complete for correct invocation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 73%, and the description adds meaningful grouping the schema lacks: castShadow/receiveShadow apply to 'any object', while bias/mapSize/shadow camera apply to lights. This clarifies several parameters (e.g., cameraNear/cameraFar have no schema descriptions) but omits how name vs uuid selection works.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: change shadow casting/receiving on objects and bias/mapSize/shadow-camera on lights. An agent can tell it apart from most siblings, though it never explicitly contrasts itself with set_light, which overlaps on light properties.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives strong context about the live-preview workflow and names pending_changes and revert_changes, but these are companions rather than alternatives — it never says when to reach for set_shadow versus set_light or set_object_transform. Usage is implied, not prescribed.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.