Skip to main content
Glama

generate_mesh

Create a textured 3D GLB mesh from one object image or a text prompt, including optional multi-view input and retopology for game-ready assets.

Instructions

Generate a textured 3D mesh (GLB with PBR materials) from an image of one object.

Give input_image (a local path), or give only prompt to first generate a reference image with the image model (a plain background suffix is added) and then mesh it. Default model: TRELLIS.2 with shape resolution 1024, 2048 px textures, 300k faces. Multi-view: also give left_image, back_image and/or right_image (views 90 degrees apart at the same scale, input_image being the front) to use Pixal3D multi-view instead. framing (multi-view only): "crop" (default) crops each view to its own outline, which suits figures; it stretches the side views of objects wider from the front than the side. "as_framed" uses square views exactly as given (object centred, about 1/1.1 of the frame at its widest, one scale for all views, as from a 3D render rig at 20 degrees horizontal FOV). remove_background=False uses the image's own alpha channel instead of BiRefNet. retopo_faces (for example 10000): also make a game weight copy with retopologize_mesh (retopo_method "quad" or "decimate"); the result's "retopo" entry has its path. retopo_lods (for example [10000, 3000, 800]) makes a LOD chain instead, as retopologize_mesh's lods. For a plain triangle mesh at a given size, face_count alone does it inside the generation. Returns the GLB path, the reference image path when one was generated, seed, settings and timings.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "generate_mesh"
  }
}

Input Schema

NameRequiredDescriptionDefault
seedNo
modelNo
promptNo
framingNocrop
back_imageNo
face_countNo
left_imageNo
output_dirNo
resolutionNo
input_imageNo
retopo_lodsNo
right_imageNo
retopo_facesNo
texture_sizeNo
retopo_methodNoquad
remove_backgroundNo
idle_timeout_secondsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations at all, the description carries the full burden and does well: it discloses concrete defaults (TRELLIS.2, shape resolution 1024, 2048 px textures, 300k faces), the background-removal mechanism (BiRefNet vs the image's own alpha), the side effect of writing a retopo copy into a "retopo" entry, and the return payload (GLB path, reference image path, seed, settings, timings). It omits operational context an agent might need, such as whether the backend must be started first or expected runtime, which keeps it from a 5.

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 core capability sentence, then organized as parenthetical-scoped parameter notes, so each sentence carries new information. The telegraphic style ("and then mesh it", "game weight copy", "at a given size") occasionally compresses to the point of ambiguity, but there is very little genuinely wasted text.

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 a 17-parameter generative tool with no annotations and no output schema, the definition covers what is produced, how inputs map to output variants, and what the return includes. The gaps are prerequisites and failure behavior — nothing says a backend must be running or what happens with an invalid path — but nothing essential to invoking it is missing.

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

Parameters5/5

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

Schema description coverage is 0% across 17 params, so the description must compensate and largely does: it explains the mutually exclusive input_image/prompt paths, the geometry of multi-view images, both framing modes including the caveat that "crop" stretches side views, remove_background's alternative source, and the distinction between retopo_faces, retopo_lods, retopo_method and face_count. Only seed, output_dir and idle_timeout_seconds go unexplained, which is a minor residue on a 17-parameter tool.

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+output format: "Generate a textured 3D mesh (GLB with PBR materials) from an image of one object." It also delineates the two input modes (image vs prompt-only) and names the model used, so an agent immediately knows what this produces and how it differs from a pure image or retopo tool.

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

Usage Guidelines4/5

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

Gives explicit selection logic among several paths: input_image vs prompt-only, single-view vs multi-view (left/back/right at 90 degrees), and a clear routing rule for geometry resolution — retopo_faces for a weighted game copy via retopologize_mesh, retopo_lods for a LOD chain, and "For a plain triangle mesh at a given size, face_count alone does it inside the generation." It does not state when to prefer this over unmentioned siblings like generate_parts or generate_turnaround, so it falls short of full when/when-not coverage.

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