Documentation
Docs/en/reference/image-format/fofrm.md
FOFRM Descriptor Reference
Generated reference. Do not edit directly. Update
BuildTools/ImageFormatInterface.json, then runpython BuildTools/docs_image_format.py --write.
| Index | Formats | FOFRM | Options | Baking | Runtime | Validation | Canonical JSON | Guide |
FOFRM is the authored composition layer for static images, animations, direction sheets, and imported legacy sources. References are relative to the descriptor directory.
| Stable ID | Field/rule | Requirement | Why | Source |
|---|---|---|---|---|
image-format.field.fps |
fps / Fps | FOFRM reads lowercase fps first and then legacy Fps; zero creates a non-playing sheet, while production animation values must also keep whole duration per frame above zero. | The authored count and fps determine whole-sheet AnimTicks, while runtime playback divides that duration by flattened frame count. | Source/Tools/ImageBaker.cpp |
image-format.field.count |
count / Count | Count is the number of descriptor references per direction, defaults to one, and must be positive; it is not necessarily the final flattened frame count. | Each referenced source can itself contain multiple frames. | Source/Tools/ImageBaker.cpp |
image-format.field.sequence-offset |
offs_x / offs_y and OffsetX / OffsetY | Sequence offsets are signed and may be authored in the root or each direction section; explicitly set both values in every direction section because omitted values carry forward. | The parser reuses the current ox/oy variables instead of resetting them for each direction. | Source/Tools/ImageBaker.cpp |
image-format.field.effect |
effect / Effect | The parser accepts effect/Effect into FrameCollection.EffectName for compatibility, but ImageBaker does not serialize or apply it and the stock runtime never selects an effect from this field. | Authors must not treat a parsed-but-unused field as a rendering contract. | Source/Tools/ImageBaker.cpp, Source/Tools/ImageBaker.h |
image-format.field.direction-section |
[dir_N] / [Dir_N] | A descriptor is either single-direction or supplies every Engine map direction; partial direction sets and later gaps fail. | SpriteSheet accepts exactly one direction or GameSettings::MAP_DIR_COUNT directions. | Source/Tools/ImageBaker.cpp, Source/Client/DefaultSprites.cpp |
image-format.field.frame-reference |
frm / Frm and frm_N / Frm_N | Every authored descriptor slot resolves one relative image path; only slot zero also accepts the unnumbered frm/Frm alias. | References are joined with the descriptor directory and then dispatched by the referenced extension. | Source/Tools/ImageBaker.cpp |
image-format.field.frame-delta |
next_x_N / next_y_N and NextX_N / NextY_N | Descriptor frame deltas are added to every flattened child frame’s imported NextX/NextY values. | This preserves source-format displacement while allowing authored composition corrections. | Source/Tools/ImageBaker.cpp |
image-format.field.flattening |
Nested sequence flattening | FOFRM appends the Main sequence of every referenced child; child direction sheets and child sequence offsets are not composed, and all authored parent directions must flatten to the same final frame count. | The merge loop copies child Main frames only and validates each later direction against collection.SequenceSize. | Source/Tools/ImageBaker.cpp |
image-format.field.timing |
FOFRM whole-sequence timing | FOFRM computes whole-sequence duration from authored descriptor count, not from the flattened child-frame count; fps zero yields zero ticks. | Nested animated references can therefore change effective frame cadence unless the author accounts for flattening. | Source/Tools/ImageBaker.cpp |