---
title: "Automatic LODs for a generated model | Spatial Compiler"
description: "Ask for a triangle target per LOD and get every level in one GLB, with the measured count, surface error and switch distance of each, and a warning when a level misses its target."
canonical: https://appliedmanifold.com/use-cases/gen3d/generated-model-lods/
site: "Applied Manifold: The spatial compute cloud for 3D reality"
---

1.  [Home](https://appliedmanifold.com/)
2.  [Use cases](https://appliedmanifold.com/use-cases/)
3.  [Generated models](https://appliedmanifold.com/use-cases/generated-models/)
4.  LOD levels

# Get LODs that report their real counts

Give your agent a triangle target for each level. meshfx writes every level into one GLB and reports the count it reached, its surface error and the distance to switch at. When a level misses its target, the report says so and names the cause.

[Get Free API Key](https://console.appliedmanifold.com/sign-in?next=/api-keys&job=generated-model) [Start with your agent](https://appliedmanifold.com/use-cases/gen3d/generated-model-lods/#get-started)

![Wireframe of a generated figure at LOD0, 20,000 triangles](/use-cases/jobs/generated-model-lods/before.webp)

![Wireframe of the same figure at LOD2, 2,000 triangles](/use-cases/jobs/generated-model-lods/after.webp)

LOD0, 20,000 triangles

LOD2, 2,000 triangles

-   **3 of 3**levels on their triangle targets
-   **1.7 cm**worst surface error at LOD2, on a 1 m figure
-   **15.7 m**switch distance the report gives for LOD2
-   **$5**Free signup credit for 50 mesh Drafts

Each dark line is a triangle edge. Both levels come from one GLB, compiled on the hosted API on 3 December 2026.

## Measured LOD counts

A level that misses its budget looks fine in the editor. You find out it is still heavy when the frame rate drops.

In a second test, a generated pair of boots kept 39,546 triangles at LOD1 against a 6,000 target. The report flagged it and named the cause: 80% of the vertices sit on the texture's seams, and the reduction keeps those edges.

## What the terms mean

-   ### LOD

    Level of detail: lighter copies of a model that the engine draws as it gets farther away.

    Distant models stop costing as much as close ones.

-   ### Surface error

    How far a lighter level's surface strays from the original, in metres.

    Your agent can compare it with what a player sees at that distance.

-   ### UV seam

    An edge where the texture layout is cut apart.

    Reduction keeps seam edges, which can hold a level above its target.

## How it works

1.  ### Send the model

    Your agent uploads a GLB, FBX, OBJ, STL or PLY over MCP, or your code calls the REST API.

2.  ### Set a target per level

    The spec lists one triangle target for each LOD. Your first 50 mesh Drafts are free with the $5 signup credit.

3.  ### Check the report

    Each level lists its measured triangles, target, surface error and switch distance. A missed target comes with a warning and its cause.

[Read how LODs work](https://appliedmanifold.com/learn/lod/)

## Questions

### Does every level hit its target?

Not always. The generated figure hit all three. The boots stopped at 39,604 and 39,546 triangles for targets of 20,000 and 6,000. The report raised a missed-budget warning for each of those levels, with its cause.

### Where do the levels go?

Into one GLB, as nodes whose names end in \_LOD0, \_LOD1 and \_LOD2. The report gives the switch distance for each level.

### Why did the boots miss?

Their texture layout put 80% of the vertices on seam edges. The reduction keeps those edges. The warning points to uv.mode as the setting to change.

[All use cases](https://appliedmanifold.com/use-cases/)

## Use with your agent

Paste the prompt into Claude Code, Cursor or Codex. Your agent connects to Spatial Compiler and comes back with a GLB with every LOD level and a report of each level's count, error and switch distance.

[Get Free API Key](https://console.appliedmanifold.com/sign-in?next=/api-keys&job=generated-model) [Try it in the Playground →](https://console.appliedmanifold.com/playground?module=meshfx&item=namaqualand_rocks)

New accounts start with $5 of usage, and you see the price of each job before it runs.

Agent prompt

Connect the Spatial Compiler MCP server at https://spatialcompiler.dev/mcp if it isn't connected yet. Use meshfx to build LOD levels for this model at 20,000, 6,000 and 2,000 triangles, then tell me the measured count, surface error and switch distance of each level and flag any level that missed its target. Run a Draft first. Your first 50 mesh Drafts are free with the $5 signup credit. Ask before running a final compile.

Or add the server yourself in Claude Code:

`claude mcp add --transport http spatial-compiler https://spatialcompiler.dev/mcp`

[Set it up in Cursor, Codex or another agent](https://appliedmanifold.com/docs/mcp/)

Once connected, your agent can call the `starter` tool. It returns a ready fire Draft spec and the exact call that runs it. Your first 100 fire Drafts are free with the $5 signup credit.
