struct

FRetargetSerializer

MDF serialization for the retargeter asset (.retarget) — UE's IK Retargeter minus the IK chains.

Module
Animation
Header
#include "Animation/RetargetSerializer.h"
Namespace
Mowo

Why an asset at all, when FRetargetOptions is already a plain struct: a name map for a real rig is dozens of pairs plus the prefix strips plus the per-bone translation modes, and it is a property of the SOURCE-to-TARGET RIG PAIR, not of any one character. Left as code, every entity that reuses the same two rigs re-declares it, and the first one to be edited without the others starts retargeting differently for no visible reason.

The name map and the per-bone mode table are both unordered_maps, so this writes their entries SORTED by key. An asset whose bytes shuffle between saves shows up as a diff in every commit that touched anything nearby, and the round-trip test could not compare text at all.

Public functions

ReturnsNameDescription
std::stringSerializeToString
boolDeserializeFromString
boolSaveToFile
boolLoadFromFileReads through the VFS so a cooked/packaged project resolves the same "Content/..." path a loose project does.

Function details

SerializeToString

C++
static std::string SerializeToString(const FRetargetOptions& options)

DeserializeFromString

C++
static bool DeserializeFromString(const std::string& text, FRetargetOptions& outOptions)

SaveToFile

C++
static bool SaveToFile(const FRetargetOptions& options, const std::string& path)

LoadFromFile

C++
static bool LoadFromFile(const std::string& path, FRetargetOptions& outOptions)

Reads through the VFS so a cooked/packaged project resolves the same "Content/..." path a loose project does.

Generated from Animation/RetargetSerializer.h via animation.json · Oct 26, 2026Version 1.0.0