set_uniform
Change a ShaderMaterial uniform in the live browser preview without editing source; changes are tracked and can be reverted.
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. Set a ShaderMaterial uniform.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"uniform": "<uniform>",
"value": "<value>"
},
"name": "set_uniform"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Material name | |
| uuid | No | Material UUID | |
| value | Yes | Hex string for Color, {x,y,z} for vectors, number/boolean for scalars | |
| uniform | Yes | Uniform name, e.g. uTime, uColor |