---
title: "pyrofx docs: bake fire, smoke, explosion and dust from a spec"
description: "Add animated fire, smoke and dust to your game as ready to use image sequences."
canonical: https://appliedmanifold.com/docs/pyrofx/
site: "Applied Manifold: The spatial compute cloud for 3D reality"
---

[Home](https://appliedmanifold.com/) / [Docs](https://appliedmanifold.com/docs/) / pyrofx

DOCS // pyrofx

# pyrofx docs

Add animated fire, smoke and dust to your game as ready to use image sequences.

## Output files

You get directional PNG or EXR texture sheets, `layout.json` with frame order, timing and channels, plus an optional Godot scene.

[![Fire](https://appliedmanifold.com/bakes/fire/strip.webp)

Fire](https://appliedmanifold.com/docs/pyrofx/examples/#ex-fire)

## Estimate and bake

First call MCP `estimate` with the request payload and check the quoted price. If approval is required and the user agrees, include the returned `quote.id` as `accept_quote` in `submit`, or use `POST /v1/estimate` then `POST /v1/jobs` over REST with the same approval flow.

fire.pyro.toml

```
[domain]
size_m = [2, 2, 2]
voxel_m = 0.06
duration_s = 0.5

[[emitters]]
shape = "sphere"
position_m = [0, 0.4, 0]
size_m = 0.3
fuel = 2
temperature_k = 1500
smoke = 1

[export]
grid = [2, 2]
tile_px = 32
```

### MCP request

JSON

```json
{
  "module": "pyro",
  "operation": "bake",
  "quality": "draft",
  "spec": "[domain]\nsize_m = [2, 2, 2]\nvoxel_m = 0.06\nduration_s = 0.5\n\n[[emitters]]\nshape = \"sphere\"\nposition_m = [0, 0.4, 0]\nsize_m = 0.3\nfuel = 2\ntemperature_k = 1500\nsmoke = 1\n\n[export]\ngrid = [2, 2]\ntile_px = 32\n"
}
```

## Engine import

| Engine | Import |
| --- | --- |
| Godot | Run the Godot wire step to build a scene that plays the directional texture sheets. |
| Unity | Load the PNG or EXR sheets and read layout.json to set grid dimensions, timing and ground anchor in a custom shader. Sample the directional channels to light the effect. |
| Unreal Engine | Sample the matching PNG cells in an Unreal material and combine the lighting channels. |
| three.js | Play the texture sheets on a quad using `layout.json` for frame timing and directional lighting. |

## Reference and examples

-   [Examples](https://appliedmanifold.com/docs/pyrofx/examples/) The hosted pyrofx recipes are fire, fireball, fire\_whirl, window\_fire, smoke\_column, smoke\_plume, dust\_ring, impact, kickup\_soil and kickup\_masonry. The rendered starter library retains its recorded compile version; each example links its report.
-   [Spec file](https://appliedmanifold.com/docs/pyrofx/spec/) A spec is a TOML file ending in `.pyro.toml` with the sections `[meta]`, `[domain]`, `[[emitters]]`, `[[forces]]`, `[[obstacles]]`, `[solver]`, `[look]`, `[[views]]` and `[export]`. Units are meters, seconds and kelvin.
-   [Emitters](https://appliedmanifold.com/docs/pyrofx/emitters/) A spec takes any number of `[[emitters]]`: spheres, boxes, discs, rings or points that add fuel, heat, smoke or dust. Key `position_m` and `rotation_deg` to move and turn them.
-   [Values over time](https://appliedmanifold.com/docs/pyrofx/values-over-time/) Any field marked animatable takes either a constant or keys over simulated seconds, such as `fuel = [[0.0, 4.0], [0.5, 0.0]]`. The value blends between keys with linear, smooth or step easing and holds outside them.
-   [Forces](https://appliedmanifold.com/docs/pyrofx/forces/) A spec takes any number of `[[forces]]`, which act on the gas in a sphere, a box or everywhere: `push`, `point`, `vortex`, `turbulence`, `drag` and `expand` (a blast).
-   [Obstacles](https://appliedmanifold.com/docs/pyrofx/obstacles/) `[[obstacles]]` are solids the gas flows around: spheres, boxes, cylinders and capsules. `carve = true` cuts holes. Keys move them; `holdout` and `shadow` hide and shade the gas.
-   [Model-shaped emitters and obstacles](https://appliedmanifold.com/docs/pyrofx/models/) Use a model as an emitter surface or volume, or as an obstacle that gas flows around. OBJ, GLB and glTF shapes are supported.
-   [Soil and masonry presets](https://appliedmanifold.com/docs/pyrofx/presets/) Set `look.material` to `soil` or `masonry` for dust colours and motion defaults. Any key you set overrides the preset.
-   [Outputs](https://appliedmanifold.com/docs/pyrofx/outputs/) With the default export, each view writes four sheets, `<view>_pos.png`, `_neg.png`, `_colour.png` and `_aux.png`, plus `layout.json`, two still previews, the animated `preview_anim.png` and `bake_report.json`. Sheets are 8 x 8 tiles of 256 px by default.
-   [Report](https://appliedmanifold.com/docs/pyrofx/report/) Every command prints the same JSON report to stdout and writes it to `bake_report.json`: `ok`, `errors`, `warnings` with a fix key and hint, `artifacts` and `metrics`. A failed run still returns a report with `ok` set to `false`. Exit codes and error codes are listed under Errors.
-   [Bake and wire](https://appliedmanifold.com/docs/pyrofx/bake-and-wire/) Call `bake` with a `.pyro.toml` spec and an output folder, then `wire` to write a Godot 4 scene with the six-way shader. `check`, `schema` and `sweep` support the loop.
-   [Godot effect pool](https://appliedmanifold.com/docs/pyrofx/godot-pool/) Draw many copies of one compiled effect in one draw call. Each copy has its own start time, size, colour, lean and mirror.
-   [Same result](https://appliedmanifold.com/docs/pyrofx/same-result/) Bake the same spec twice and you get the same sheets back. We ran the official fire example twice at draft quality, and every sheet had the same SHA-256 hash.

## Questions

### How do I estimate and submit a pyrofx bake?

Call MCP estimate with your payload to check the price, then pass the returned quote ID as accept\_quote in submit.

### What files does a pyrofx bake output?

Each view outputs directional PNG or EXR texture sheets, layout.json for timing and channels, preview images and bake\_report.json.

### How do Unity, Unreal Engine and three.js import pyrofx sheets?

They load the PNG or EXR sheets and read layout.json to set grid dimensions, frame timing and directional lighting channels.
