---
title: "meshfx compiled examples"
description: "Complete meshfx specs and outputs for the Namaqualand rocks, articulated washing machine and rubble palette prop."
canonical: https://appliedmanifold.com/docs/mesh/examples/
site: "Applied Manifold: The spatial compute cloud for 3D reality"
---

[Home](https://appliedmanifold.com/) / [Docs](https://appliedmanifold.com/docs/) / [meshfx](https://appliedmanifold.com/docs/mesh/) / Examples

DOCS // meshfx

# meshfx compiled examples Available

Compile the Namaqualand rock scan, articulated washing machine or rubble palette prop into reduced GLB levels of detail with layout.json.

meshfx runs on the hosted API: try it in the [Playground](https://appliedmanifold.com/playground/).

Compile a rock scan, an articulated appliance or a rubble heap into engine-ready GLB levels of detail with these complete specs.

## Repair the Namaqualand rock scan

Clean up an 85,716-triangle rock scan with two zero-area faces and build three LODs while keeping the original UVs and textures.

![Namaqualand rock scan compiled into three levels of detail](https://appliedmanifold.com/showcase/hosted/namaqualand-rocks/lod_lineup_shaded_1600.webp)

Four textured stones reduced from 85,716 triangles to 24,998, 12,498 and 6,250 triangles.

The [Namaqualand Rocks 01 scan from Poly Haven](https://polyhaven.com/a/namaqualand_rocks_01) is available under CC0. Pack the mesh and textures into one GLB and set source.file to that file.

This spec keeps source UVs, removes collapsed faces and targets 25,000, 12,500 and 6,250 triangles across the four stones.

namaqualand\_rocks.meshfx.toml

```
# Repair a scanned group of rocks and build lighter meshes for distant views.
# Use the packed Namaqualand Rocks 01 GLB (Poly Haven, CC0). See README.md.
[meta]
name = "namaqualand_rocks"

[source]
kind = "scan"
file = "namaqualand_rocks_01.glb"

[units]
size_m = 1.4

[repair]
enabled = true
resolve_crossings = true
fill_holes = "all"

# Shared triangle budgets for the four stones.
[simplify]
triangles = 25000

[lod]
triangles = [12500, 6250]

[uv]
mode = "keep"

[bake]
source_detail = false
vertex_colour = "keep"

[collision]
mode = "none"

[export]
compression = "none"
lod_layout = "files"
textures_in = "beside"
name_style = "keep"
```

meshfx outputs three GLB levels at 24,998, 12,498 and 6,250 triangles across the four stones, plus three JPEG texture maps and a layout file.

| File | What it is |
| --- | --- |
| `namaqualand_rocks_LOD0.glb``namaqualand_rocks_LOD1.glb``namaqualand_rocks_LOD2.glb` | Three detail levels of the four-stone set to load into your LOD group. |
| `namaqualand_rocks_base_colour.jpg``namaqualand_rocks_normal.jpg``namaqualand_rocks_metallic_roughness.jpg` | Base colour, normal and metallic roughness maps kept from the scan |
| `layout.json` | LOD filenames and switch distances for engine loading |

Load the three GLB levels into Godot or three.js, keep the three JPEG maps alongside them and switch levels at the distances in godot/layout.json.

| Engine | Import |
| --- | --- |
| Godot | Import each GLB as a scene, use the layout level order and visibility ranges to switch meshes, or instantiate the .tscn with articulated.gd and call set\_joint("door\_hinge", angle\_radians) on the root. |
| Unity | Import the GLB with materials and vertex colors intact, derive LOD Group screen-relative thresholds from the layout distances for your game camera, or rotate and translate named pivots along their exported local axes. |
| Unreal Engine | Import the GLB through Interchange, build the Static Mesh LOD chain from the level files, or keep moving meshes under their pivots in a Blueprint using centimetres and degrees. |
| three.js | Load each GLB with GLTFLoader into a THREE.LOD using layout switch distances, or find pivots with getObjectByName to rotate or translate them relative to their rest transforms. |

[Download input GLB](https://appliedmanifold.com/showcase/hosted/inputs/namaqualand_rocks_01.glb) · [Hosted output files](https://api.spatialcompiler.dev/share/AWsrDwBqb2JfYXBwc3drMmtlejlhMHBmbnM4ZTkYBQCZGL2OJNFVZMLSLF0H4E-e6uTc2NrZFgw2U_NXx5QCRon9gVqi_g)

## Keep the washer door on its hinge

Compile an articulated washing machine into three GLB levels of detail while keeping all seven rigid parts and four moving joints intact.

![Articulated washing machine with open door and extended drawer](https://appliedmanifold.com/showcase/hosted/washer/articulated_1600.webp)

Articulated washing machine compiled into three levels of detail with seven rigid parts and four joints.

The articulated appliance example preserves the cabinet, door hinge, detergent drawer and rotating drum across LODs.

The spec preserves the input pivot hierarchy so meshfx processes each rigid part separately without merging the frame, door, drawer or drum.

washing\_machine.meshfx.toml

```
# Sandflow washing machine from sand3d 1.6.3, Apache-2.0.
# From the repository root, stage the recipe and licensed fixture together:
# mkdir -p /tmp/spc-washer
# cp plugin/skills/meshfx/examples/washing_machine.meshfx.toml /tmp/spc-washer/
# cp tests/data/sand3d/{washing_machine.glb,LICENSE,NOTICE} /tmp/spc-washer/
# spc bake /tmp/spc-washer/washing_machine.meshfx.toml --out /tmp/spc-washer/bake
[source]
file = "washing_machine.glb"
hierarchy = "tree"

[units]
pivot = "keep"

[simplify]
triangles = 3000

[lod]
triangles = [1700, 950]

[collision]
mode = "none"

[export]
lod_layout = "files"

# The source uses solid part colours and has no UV set for a detail map.
[bake]
source_detail = false

[uv]
mode = "keep"
```

meshfx outputs three articulated GLB levels at 2,940, 1,700 and 950 triangles with 7 reported draw calls, plus a layout file and optional Godot scene and script.

| File | What it is |
| --- | --- |
| `washing_machine_LOD0.glb``washing_machine_LOD1.glb``washing_machine_LOD2.glb` | Three articulated detail levels of the appliance to load with preserved pivots. |
| `layout.json` | LOD switch distances plus pivot names and joint limits |
| `washing_machine.tscn``articulated.gd` | Optional Godot scene and script exposing get\_joints() and set\_joint() |

Instance godot/washing\_machine.tscn in Godot and call set\_joint() on godot/articulated.gd, or load the GLB levels in three.js and drive the named pivot nodes.

| Engine | Import |
| --- | --- |
| Godot | Import each GLB as a scene, use the layout level order and visibility ranges to switch meshes, or instantiate the .tscn with articulated.gd and call set\_joint("door\_hinge", angle\_radians) on the root. |
| Unity | Import the GLB with materials and vertex colors intact, derive LOD Group screen-relative thresholds from the layout distances for your game camera, or rotate and translate named pivots along their exported local axes. |
| Unreal Engine | Import the GLB through Interchange, build the Static Mesh LOD chain from the level files, or keep moving meshes under their pivots in a Blueprint using centimetres and degrees. |
| three.js | Load each GLB with GLTFLoader into a THREE.LOD using layout switch distances, or find pivots with getObjectByName to rotate or translate them relative to their rest transforms. |

[Download input GLB](https://appliedmanifold.com/showcase/hosted/inputs/washing_machine.glb) · [Hosted output files](https://api.spatialcompiler.dev/share/AWsrDwBqb2JfZGtkNzRleTQ4a3R6ZjY5aDZiYmEYv-Hce9SOuWthFN-BjOeENKOE5aghnupq_L4iTvFM6UgxHgYLWkwpjQ)

## Rubble heap with vertex colours

Reduce a 101,760-triangle, 4 m rubble heap into two GLB levels of detail while keeping its vertex colours.

![Compiled 4 m rubble heap with vertex colours](https://appliedmanifold.com/showcase/hosted/palette-prop/lod_lineup_shaded_1600.webp)

Rubble heap reduced from 101,760 triangles to 20,000 and 1,500 triangles with vertex colours preserved.

The spec targets 20,000 and 1,500 triangles and preserves vertex colours without external texture maps.

palette\_prop.meshfx.toml

```
# Keep the rubble heap’s vertex colours as its triangle count drops with distance.
# Generate palette_prop.glb using the command in README.md.
[meta]
name = "palette_prop"

[source]
file = "palette_prop.glb"

[units]
size_m = 4.0                # the heap is 4 m long

[simplify]
triangles = 20000           # the game's prop LOD0

[lod]
triangles = [1500]          # LOD0 plus one low mesh for its 40 m camera

[collision]
mode = "none"

[uv]
mode = "keep"

[bake]
source_detail = false
vertex_colour = "keep"

[export]
targets = ["godot"]
forward = "-z"
name_style = "lower_snake"
compression = "none"
lod_layout = "files"
```

meshfx outputs two GLB levels at 20,000 and 1,500 triangles with 1 reported draw call and a layout file.

| File | What it is |
| --- | --- |
| `palette_prop_LOD0.glb``palette_prop_LOD1.glb` | Two detail levels of the rubble heap with vertex colours to load into your LOD group. |
| `layout.json` | LOD filenames and switch distances for engine loading |

Load both GLBs into Godot or three.js, assign a material that reads vertex colour and switch levels using godot/layout.json.

| Engine | Import |
| --- | --- |
| Godot | Import each GLB as a scene, use the layout level order and visibility ranges to switch meshes, or instantiate the .tscn with articulated.gd and call set\_joint("door\_hinge", angle\_radians) on the root. |
| Unity | Import the GLB with materials and vertex colors intact, derive LOD Group screen-relative thresholds from the layout distances for your game camera, or rotate and translate named pivots along their exported local axes. |
| Unreal Engine | Import the GLB through Interchange, build the Static Mesh LOD chain from the level files, or keep moving meshes under their pivots in a Blueprint using centimetres and degrees. |
| three.js | Load each GLB with GLTFLoader into a THREE.LOD using layout switch distances, or find pivots with getObjectByName to rotate or translate them relative to their rest transforms. |

[Download input GLB](https://appliedmanifold.com/showcase/hosted/inputs/palette_prop.glb) · [Hosted output files](https://api.spatialcompiler.dev/share/AWsrDwBqb2JfNDQwNjZwZmRnZDBiZTVtYXgwOTYY-f53XVvZv5gZDHv8cgyKH4jBJMiAfygXtvwPj-4Mu0f2Amygsj1evg)

## Questions

### How many triangles remain in the Namaqualand rock scan after meshfx reduction?

meshfx reduces the four textured stones from 85,716 input triangles to three levels with 24,998, 12,498 and 6,250 triangles.

### What files does meshfx output for the Namaqualand rock scan example?

meshfx outputs three GLB level files, three JPEG maps for base colour, normal and metallic roughness, plus layout.json.

### How does the washing machine example preserve its moving parts?

The spec preserves the input pivot hierarchy so meshfx processes all seven rigid parts and four joints separately across three detail levels.
