inspect_redshift_materials
Inspect Redshift materials in Cinema 4D scenes to analyze names, assignments, colors, descriptions, and node graphs with fallback options when Redshift runtime is unavailable.
Instructions
Inspect Redshift materials with best-effort fallbacks.
This tool is read-only and is designed to be useful even when the Redshift
Python runtime is unavailable. It can still report names, assignments,
preview-derived colors, readable description/container fields, and will
attempt graph inspection only when Cinema 4D exposes that data.
Args:
material_name: Optional material name filter
include_assignments: Include texture-tag assignments in the scene
include_preview: Include sampled preview bitmap color data
include_description: Include readable description entries
include_container: Include safe BaseContainer values
include_graph: Attempt node-graph inspection when availableInput Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| material_name | No | ||
| include_assignments | No | ||
| include_preview | No | ||
| include_description | No | ||
| include_container | No | ||
| include_graph | No |
Implementation Reference
- src/cinema4d_mcp/server.py:586-632 (handler)The implementation of the `inspect_redshift_materials` tool handler. It establishes a connection to Cinema 4D, constructs a command dictionary, sends it, and returns the formatted JSON response.
async def inspect_redshift_materials( material_name: Optional[str] = None, include_assignments: bool = True, include_preview: bool = True, include_description: bool = True, include_container: bool = True, include_graph: bool = True, ctx: Context = None, ) -> str: """ Inspect Redshift materials with best-effort fallbacks. This tool is read-only and is designed to be useful even when the Redshift Python runtime is unavailable. It can still report names, assignments, preview-derived colors, readable description/container fields, and will attempt graph inspection only when Cinema 4D exposes that data. Args: material_name: Optional material name filter include_assignments: Include texture-tag assignments in the scene include_preview: Include sampled preview bitmap color data include_description: Include readable description entries include_container: Include safe BaseContainer values include_graph: Attempt node-graph inspection when available """ async with c4d_connection_context() as connection: if not connection.connected: return "❌ Not connected to Cinema 4D" command = { "command": "inspect_redshift_materials", "include_assignments": include_assignments, "include_preview": include_preview, "include_description": include_description, "include_container": include_container, "include_graph": include_graph, } if material_name: command["material_name"] = material_name response = send_to_c4d(connection, command) if "error" in response: return f"❌ Error: {response['error']}" return json.dumps(response, indent=2) - src/cinema4d_mcp/server.py:585-585 (registration)Tool registration using the `@mcp.tool()` decorator for the `inspect_redshift_materials` function.
@mcp.tool()