Skip to main content
Glama

Generate PBR maps from an image

material_from_image
DestructiveIdempotent

Turn ONE uploaded image (e.g. a logo PNG) into a full PBR material — deterministic, no AI. A mask (alpha channel, or bright/dark regions) drives derived roughness (baseRoughness/maskRoughness), embossed normal + height maps, optional metallic, and a base color composited over baseColor. Commits a new revision with the material (applyToObjects assigns it); maps pack into the .blend. Generated maps cap at 2048px on the longest edge — for full-resolution label/print work (4K macro shots), embed the original texture in a GLB and import via asset_import. Flow: upload_create → PUT → upload_complete → material_from_image. Returns a durable job handle. Explicit profile=surface/decal/supplied opts into the version-2 downloadable map workflow with roles and options; legacy mask/emboss arguments apply only when profile is omitted. Decals preserve transparency without implicit relief or metallic.

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": {
      "projectId": "<projectId>",
      "assetId": "<assetId>",
      "idempotencyKey": "<idempotencyKey>"
    },
    "name": "material_from_image"
  }
}

Input Schema

NameRequiredDescriptionDefault
rolesNo
embossNo
assetIdYes
optionsNo
profileNo
baseColorNo
projectIdYesStable project ID returned by project_create or projects_list.
maskSourceNoalpha
baseMetallicNo
maskMetallicNo
materialNameNoImage Material
baseRoughnessNo
maskRoughnessNo
applyToObjectsNo
baseRevisionIdNo"HEAD" (default) targets the project's current head. Mutations MUST build on the head: passing an older revision is rejected with REVISION_CONFLICT, since history is linear. To continue from an older scene, revision_restore it forward first.HEAD
idempotencyKeyYesStable caller-chosen key for safe retries of this same request.

Output Schema

NameRequiredDescriptionDefault
jobYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed23 schema fields changed
    • addedInput schema / properties / options / properties / alphaCutoff / description
      Added value: +"Mask-mode alpha threshold, 0-1; default 0.5. Ignored by opaque/blend modes."
    • addedInput schema / properties / options / properties / alphaMode / description
      Added value: +"Material opacity behavior. Default opaque, or blend for decal profile; delivered PNG alpha is preserved regardless."
    • addedInput schema / properties / options / properties / displacementMode / description
      Added value: +"How the material uses height: none (default), shader bump, or displacement. A height map must be available; renderer/export support varies."
    • addedInput schema / properties / options / properties / emissionStrength / description
      Added value: +"Material emission multiplier, 0-10000; default 1 when emission is requested, otherwise 0. Requires an emission output to light the material."
    • addedInput schema / properties / options / properties / heightMidlevel / description
      Added value: +"Height value representing zero displacement, 0-1; default 0.5."
    • addedInput schema / properties / options / properties / heightScale / description
      Added value: +"Relief height in meters, 0-1; default 0.001. Used for height-derived normals and material bump/displacement."
    • addedInput schema / properties / options / properties / heightSource / description
      Added value: +"If no height map is supplied, explicitly allow height estimation from base_color luminance or alpha. Default none; estimated relief is labeled heuristic."
    • addedInput schema / properties / options / properties / maxSize / description
      Added value: +"Maximum output side in pixels, 8-4096; default 2048. Sources are aligned at their common aspect ratio without upscaling."
    • addedInput schema / properties / options / properties / metallic / description
      Added value: +"Constant metallic fallback, 0-1; default 0. Supplied metallic maps take precedence; brightness does not establish metalness."
    • addedInput schema / properties / options / properties / normalConvention / description
      Added value: +"Convention of supplied normal maps: OpenGL +Y (default) or DirectX -Y. A change to output convention flips the green channel."
    • addedInput schema / properties / options / properties / normalStrength / description
      Added value: +"Normal intensity multiplier, 0-16; default 1. Applied when converting supplied vectors or deriving normals from height."
    • addedInput schema / properties / options / properties / outputNormalConvention / description
      Added value: +"Convention for delivered normal maps, OpenGL +Y by default or DirectX -Y; the Blender material compensates for the output convention."
    • addedInput schema / properties / options / properties / packing / description
      Added value: +"Optional extra packed PNG: ORM uses red=ambient occlusion, green=roughness, blue=metallic; default none. Missing AO uses a documented white fallback."
    • addedInput schema / properties / options / properties / physicalCoverageMeters / description
      Added value: +"Real dimensions of one UV tile for height-to-normal scaling. If omitted, derived relief normals assume a one-meter UV square."
    • addedInput schema / properties / options / properties / physicalCoverageMeters / properties / height / description
      Added value: +"Physical height in meters represented by one complete texture tile; positive, at most 100000."
    • addedInput schema / properties / options / properties / physicalCoverageMeters / properties / width / description
      Added value: +"Physical width in meters represented by one complete texture tile; positive, at most 100000."
    • addedInput schema / properties / options / properties / roughness / description
      Added value: +"Constant roughness fallback, 0-1; default 0.65. A supplied roughness map or converted gloss map takes precedence."
    • addedInput schema / properties / options / properties / roughnessMode / description
      Added value: +"Fallback roughness generation: constant (default) or an explicitly requested base_color brightness estimate. Image-derived roughness is heuristic, not measured."
    • addedInput schema / properties / options / properties / roughnessRange / description
      Added value: +"[minimum, maximum] roughness for image estimates, increasing within 0-1; default [0.35, 0.85]."
    • addedInput schema / properties / options / properties / seamMode / description
      Added value: +"Analyze edges only (default) or blend edge pixels along tile axes. Blending changes imagery and may cause ghosting; inspect the repeat preview."
    • addedInput schema / properties / options / properties / specular / description
      Added value: +"Constant specular fallback, 0-1; default 0.5. Supplied specular maps take precedence."
    • addedInput schema / properties / options / properties / tile / description
      Added value: +"Texture axes to treat as periodic for relief and seam handling; default none. Does not guarantee perceptually seamless repetition."
    • addedInput schema / properties / roles / items / description
      Added value: +"Semantic map role; use one source per role. Color maps and scalar/vector data maps are interpreted differently."
  2. Changed8 schema fields changed
    • addedInput schema / properties / baseColor / items
      Added value: +{
      +  "maximum": 1,
      +  "minimum": 0,
      +  "type": "number"
      +}
    • addedInput schema / properties / baseColor / maxItems
      Added value: +4
    • addedInput schema / properties / baseColor / minItems
      Added value: +4
    • removedInput schema / properties / baseColor / prefixItems
      Removed value: -[
      -  {
      -    "maximum": 1,
      -    "minimum": 0,
      -    "type": "number"
      -  },
      -  {
      -    "maximum": 1,
      -    "minimum": 0,
      -    "type": "number"
      -  },
      -  {
      -    "maximum": 1,
      -    "minimum": 0,
      -    "type": "number"
      -  },
      -  {
      -    "maximum": 1,
      -    "minimum": 0,
      -    "type": "number"
      -  }
      -]
    • addedInput schema / properties / options / properties / roughnessRange / items
      Added value: +{
      +  "maximum": 1,
      +  "minimum": 0,
      +  "type": "number"
      +}
    • addedInput schema / properties / options / properties / roughnessRange / maxItems
      Added value: +2
    • addedInput schema / properties / options / properties / roughnessRange / minItems
      Added value: +2
    • removedInput schema / properties / options / properties / roughnessRange / prefixItems
      Removed value: -[
      -  {
      -    "maximum": 1,
      -    "minimum": 0,
      -    "type": "number"
      -  },
      -  {
      -    "maximum": 1,
      -    "minimum": 0,
      -    "type": "number"
      -  }
      -]
  3. Changed3 schema fields changed
    • addedInput schema / properties / options
      Added value: +{
      +  "additionalProperties": false,
      +  "properties": {
      +    "alphaCutoff": {
      +      "maximum": 1,
      +      "minimum": 0,
      +      "type": "number"
      +    },
      +    "alphaMode": {
      +      "enum": [
      +        "opaque",
      +        "mask",
      +        "blend"
      +      ],
      +      "type": "string"
      +    },
      +    "displacementMode": {
      +      "enum": [
      +        "none",
      +        "bump",
      +        "displacement"
      +      ],
      +      "type": "string"
      +    },
      +    "emissionStrength": {
      +      "maximum": 10000,
      +      "minimum": 0,
      +      "type": "number"
      +    },
      +    "heightMidlevel": {
      +      "maximum": 1,
      +      "minimum": 0,
      +      "type": "number"
      +    },
      +    "heightScale": {
      +      "maximum": 1,
      +      "minimum": 0,
      +      "type": "number"
      +    },
      +    "heightSource": {
      +      "enum": [
      +        "none",
      +        "luminance",
      +        "alpha"
      +      ],
      +      "type": "string"
      +    },
      +    "maxSize": {
      +      "maximum": 4096,
      +      "minimum": 8,
      +      "type": "integer"
      +    },
      +    "metallic": {
      +      "maximum": 1,
      +      "minimum": 0,
      +      "type": "number"
      +    },
      +    "normalConvention": {
      +      "enum": [
      +        "opengl",
      +        "directx"
      +      ],
      +      "type": "string"
      +    },
      +    "normalStrength": {
      +      "maximum": 16,
      +      "minimum": 0,
      +      "type": "number"
      +    },
      +    "outputNormalConvention": {
      +      "enum": [
      +        "opengl",
      +        "directx"
      +      ],
      +      "type": "string"
      +    },
      +    "packing": {
      +      "enum": [
      +        "none",
      +        "orm"
      +      ],
      +      "type": "string"
      +    },
      +    "physicalCoverageMeters": {
      +      "additionalProperties": false,
      +      "properties": {
      +        "height": {
      +          "exclusiveMinimum": 0,
      +          "maximum": 100000,
      +          "type": "number"
      +        },
      +        "width": {
      +          "exclusiveMinimum": 0,
      +          "maximum": 100000,
      +          "type": "number"
      +        }
      +      },
      +      "required": [
      +        "width",
      +        "height"
      +      ],
      +      "type": "object"
      +    },
      +    "roughness": {
      +      "maximum": 1,
      +      "minimum": 0,
      +      "type": "number"
      +    },
      +    "roughnessMode": {
      +      "enum": [
      +        "constant",
      +        "luminance",
      +        "inverted_luminance"
      +      ],
      +      "type": "string"
      +    },
      +    "roughnessRange": {
      +      "prefixItems": [
      +        {
      +          "maximum": 1,
      +          "minimum": 0,
      +          "type": "number"
      +        },
      +        {
      +          "maximum": 1,
      +          "minimum": 0,
      +          "type": "number"
      +        }
      +      ],
      +      "type": "array"
      +    },
      +    "seamMode": {
      +      "enum": [
      +        "analyze",
      +        "blend"
      +      ],
      +      "type": "string"
      +    },
      +    "specular": {
      +      "maximum": 1,
      +      "minimum": 0,
      +      "type": "number"
      +    },
      +    "tile": {
      +      "enum": [
      +        "none",
      +        "x",
      +        "y",
      +        "xy"
      +      ],
      +      "type": "string"
      +    }
      +  },
      +  "type": "object"
      +}
    • addedInput schema / properties / profile
      Added value: +{
      +  "enum": [
      +    "surface",
      +    "decal",
      +    "supplied"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / roles
      Added value: +{
      +  "items": {
      +    "enum": [
      +      "base_color",
      +      "normal",
      +      "height",
      +      "roughness",
      +      "metallic",
      +      "opacity",
      +      "emission",
      +      "ao",
      +      "specular",
      +      "specular_color",
      +      "gloss",
      +      "cavity",
      +      "diffuse"
      +    ],
      +    "type": "string"
      +  },
      +  "maxItems": 13,
      +  "minItems": 1,
      +  "type": "array"
      +}
  4. First observed

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already declare write, destructive, and idempotent behavior, and the description adds important context: it commits a new revision, applyToObjects assigns the material, maps pack into the .blend, generated maps cap at 2048px, and a durable job handle is returned. It does not discuss permissions or rate limits, but it discloses the main side effects an agent needs to know before invoking a destructive tool.

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?

The description is dense but front-loaded: it states the core operation first, then behavioral effects, then flow, then the profile/legacy distinction. There is little filler, though some sentences pack several concepts together and require careful reading.

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 complex destructive tool with 16 parameters and an output schema, the description covers the essential context: source requirements, deterministic behavior, revision commit, map packing, 2048px cap, required upload flow, job handle, profile mode split, and decal transparency. It omits detailed guidance on many nested options, but the schema documents them and the output schema means return values need not be explained at length.

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

Parameters3/5

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

Schema description coverage is only 19%, so the description must carry more weight. It names and explains key parameters such as baseRoughness/maskRoughness, baseColor compositing, applyToObjects, and the crucial rule that legacy mask/emboss arguments apply only when profile is omitted. However, many nested options (tile, seamMode, heightSource, displacementMode, packing, normal conventions) are left to the schema and are not clarified in the description.

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: it turns ONE uploaded image into a full PBR material and is deterministic, with no AI. It distinguishes itself from AI generation and from the full-resolution asset_import path, but it never names the closest sibling material_from_maps, so differentiation from that alternative is left implicit.

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 a clear operational flow (upload_create → PUT → upload_complete → material_from_image) and an explicit alternative for 4K label/print work: embed the original in a GLB and use asset_import. It does not say when to choose material_from_maps or texture_maps_create instead, so the guidance is clear but not exhaustive.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources