Skip to main content
Glama

match_camera

Find a perspective camera that matches a 3D model's silhouette to a reference photo by tuning position, rotation, roll and field of view; the created camera becomes the scene camera.

Instructions

Find the camera that shows the model like a perspective photo of the real object (for flat orthographic views use compare_view). It tunes position, rotation, roll and field of view until the model silhouette best matches the reference silhouette. The camera camera is created or updated and becomes the scene camera. The answer has location, rotation, look_at, fov_deg and the IoU before and after. Give the whole original photo, not a crop: the picture frame is the camera frame. The outline comes from alpha or from the corner colour (plain background); threshold is the colour distance. Start: init {"location": [x,y,z], "look_at": [x,y,z], "fov_deg": 40}, else the active perspective camera, else 8 azimuths at 2 elevations are tried. A close start gives a better result. fov_deg fixes the angle across the LONGER image side: a known lens is far more reliable, because distance and field of view trade off. ground_z keeps the camera above that height. size is the working resolution; iterations is how many times the step is halved. A silhouette does not tell front from back on a symmetric model: check with overlay_reference. Background job: after wait seconds the answer is a job id for job_status.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
initNo
sizeNo
waitNo
namesNo
cameraNomatch_cam
fov_degNo
ground_zNo
referenceYes
thresholdNo
iterationsNo
time_limitNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.0

TDQS

A4.7/5.0
Behavior5/5

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

With no annotations, the description carries the full burden and does: it states the camera is created or updated and becomes the scene camera, lists the returned fields (location, rotation, look_at, fov_deg, IoU before/after), and discloses the async behavior (after `wait` seconds the result is a job id for job_status). The occlusion/alpha threshold behavior and the symmetric-model front/back caveat are also surfaced.

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?

Front-loaded with the purpose and the alternative, then dense operational detail. Nearly every sentence earns its place, though the middle paragraphs are telegraphic and a few clauses (e.g. the fov_deg/distance trade-off) are terse enough to risk misreading.

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?

For an 11-parameter, long-running optimization tool with no annotations and no output schema, the description supplies return fields, init heuristics, resolution budget and job handling. Only the unmentioned time_limit and names parameters keep it from being fully complete.

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 0% for 11 parameters, so the description must compensate and largely does: it explains init, reference ('give the whole original photo, not a crop'), fov_deg, ground_z, size, iterations, camera, wait and background-job semantics. It never explains time_limit or names, leaving two parameters undocumented.

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

Purpose5/5

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

Opens with a specific verb+resource ('Find the camera that shows the model like a perspective photo') and immediately names the sibling it is not for flat orthographic views (compare_view). The optimization goal — tuning position, rotation, roll and FOV to match the silhouette — is unambiguous.

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

Usage Guidelines5/5

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

Explicitly routes orthographic cases to compare_view and silhouette-ambiguity checks to overlay_reference, and specifies start conditions ('init' dict, else active perspective camera, else 8 azimuths x 2 elevations) plus when the call degrades to a background job. Named alternatives and conditions make the selection decision inferable.

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