Skip to content
nodemode-ai edited this page Nov 25, 2026 · 1 revision

GoF

GoF is the Form family's hand-off: a shared folder with the model as a GLB or FBX and a small gof.json that describes it. FormRig sends rigged characters out with their skeleton and skin, and receives models from formsculpt.

Send

File, Send to..., or the Send to block in the Export tab. Targets:

Target File How it is made
formcraft, formfabric, formsurface, Blender, any app GLB the Blender export profile
Unity FBX the Unity profile
Unreal FBX the Unreal profile

Files go to <data>/GoF as <stem>_<target>.<ext>, so targets never overwrite each other. gof.json follows formsculpt's shape (gof, app, version, up_axis, mm_per_unit, objects) plus skin, joints, profile and up for each entry. The profile's check runs first; a profile with error findings writes nothing and says why. The window shows which of formcraft, formfabric and formsurface are running (a green dot) by asking their local health route; Blender, Unity, Unreal and Any show no dot.

Receive

The receive folder is FORMSCULPT_GOF when set, otherwise ~/Formsculpt/GoF. Entries addressed to FormRig, or any GLB there, appear in the Received section on Home. Import opens the file in the current session through the normal unsaved changes prompt. A model is marked seen when imported, so a resend appears as new. A new arrival while FormRig is open raises a toast with Import.

Unity and Unreal

integrations/unity is an editor script that watches the GoF folder and imports the FBX into Assets/GoF with its skeleton and skin. integrations/unreal is a Python script that imports into /Game/GoF. Each has its own README. Neither was run inside the real editor; they follow the vendors' API references and formsculpt's receivers. The Unity script compiles with Mono's mcs and the return writer ran on stand-in data; the Unreal script passes py_compile and ran against a stand-in unreal module. Edits made in the editor come back through Send edits back, below.

Send edits back

Weights you paint, joints you move and shapes you edit in Unity or Unreal can return to the FormRig document they came from.

  1. In FormRig, send to Unity or Unreal as before. Every send also writes a small send record under <data>/GoF/.sends/: a fingerprint of the document (joint names, mesh names, vertex counts), the joint names, the morph names and a hash of every weight row. gof.json gains doc and record for the entry.
  2. In Unity choose Tools > FormRig > Send Edits Back (or Send Edits Back (selected)). In Unreal run formrig_gof.send_back() in the Python console with the skeletal mesh selected. Each script writes a GLB (an FBX in Unreal as a fallback) with the id of the send inside, a <name>.frgreturn file and an entry in a Return folder of the GoF folder.
  3. FormRig sees the new file within a second (the folder is polled once a second, and a file is read only after it has stopped changing). A toast says edits arrived. The Export tab has a Received edits card under Send.

The Received edits card

The card shows where the file came from (Unity or Unreal, the file, how long ago) and a status: New, Reviewed, Applied or Ignored. When several returns wait, From picks one. Its rows say what changed, measured against the open document:

Row Meaning
Vertices matched how many returned vertices found their FormRig vertex, by vertex number or by position
Rows edited weight rows that differ, out of the rows compared
Size of change how many edited rows changed by 0.0001 to 0.001, up to 0.01, up to 0.1 and above 0.1
Joints touched the joints whose weights changed most (the full list is on hover)
Joint changes joints added, renamed or removed in the editor
Shapes changed shapes whose deltas changed, out of the shapes matched
Fitted to the scale and axis flip found between the two files

Buttons: Review again reads the file again, Apply edits writes the edited rows as one undo step, Ignore dismisses the return. Take changed shapes (off by default) also takes changed shape deltas. Rows that were not edited keep their exact values, so a return with no edits changes nothing. Notes under the card say when the file came from a different model, when rows were also changed in FormRig since the send, and when rows have more influences than the engine keeps (4 for Unity, 8 for Unreal); such rows are skipped.

The two files are never assumed to share axes or units. FormRig fits one scale and one of the 48 axis permutations (24 turns, 24 mirrors) by comparing the vertices, so Unity's flipped X, a 180 degree Unreal turn and Unreal's centimetres are found rather than assumed. Joints are matched by the id in the file, then by name, then by rest position, which finds a renamed hips or an inserted root.

A re-meshed return

If a vendor tool or an artist changed the topology, the returned mesh no longer lines up vertex for vertex and the card says so. The button then reads Apply by transfer: the returned mesh is moved into the document's frame and its weights are transferred onto the open mesh by closest point (see Weight tools). Measured on Michelle with the returned vertices moved by 0.05, 0.3 and 1 mm, 2.0, 7.1 and 18.3 percent of rows changed by more than 0.01.

Measured

On Xbot and Michelle, with 10 rows edited and the returned files made to look like the editors' exports (Unity mirror and net, an Unreal turn with 3 percent split vertices, an inserted root and a renamed hips, Unreal in centimetres): 8 of 8 runs reported exactly the 10 edited rows, with no false positive and no missed row. A return with no edits reported 0 of 28,372 (Xbot) and 16,338 (Michelle) rows. Applying wrote the edited rows within 1.1e-5 of the intended ones, left the rest byte equal, and undo restored them exactly. A real Unity or Unreal editor has not been used, so how the editors' own importers reorder vertices and name bones is still to confirm there.

Hop into a running app

Two files make the hop work:

  • <data>/engine.json is written when FormRig's service starts and removed when it stops cleanly. It holds the port, process id, version, data folder, GoF folder and Return folder, and never a token. A leftover file after a crash is told apart by asking GET /api/health on that port. The editor scripts read it to find the Return folder of the running FormRig.
  • <name>.frgreturn is the return manifest, a small JSON file (app, send, doc, file, format). It is the file handed to FormRig on a command line, and .frgreturn is registered as a file type of the desktop app, so a double click opens it. A second launch passes it to the running window (single instance on Windows and Linux, the open event on macOS). The shell posts the path straight to the service, so the page need not be loaded; if the service is not up yet, the path waits and is posted when it is. A post took 6 ms; a file dropped in the Return folder raised the card in 0.60 s. The macOS and Windows paths of the shell have not been built here.

An agent can do the same with POST /api/agent {"command":"apply_return","path":"<.frgreturn>","apply":false}; apply: true also applies the edits. The rule is the one for load_rig.

Agent link

Another app can push a file into an open FormRig with POST /api/agent {"command":"load_rig","path":...}. It is accepted when the request carries the window token, or when Agent link is on (a switch stored in <data>/agent_link.json). Only load_rig exists; a .frig opens as a project and anything else imports.

Limits

  • Skin data flows from other apps into FormRig as a model with a skin, or as a return from Unity or Unreal.
  • Sending edits back is built for Unity and Unreal only. There is no return script for Blender or other apps, and hopping into an already running sister app (formcraft, formfabric, formsurface) after a send is not built; the hop described above is into FormRig.
  • A return does not carry weights beyond 8 influences, a second skin, or vertices shared by several meshes blended; an FBX holds one weight row per position, so the unedited half of a hard edge pair can read as edited (12 reported for 10 on Michelle in the Unreal FBX profile).
  • formcraft's FBX converter fails on a FormRig FBX that embeds an animation with morph tracks; turn off embedded animation for that target.

Clone this wiki locally