Momentum
A library for solving nonlinear optimization problems related to human body kinematics
Loading...
Searching...
No Matches
character_io.h File Reference
#include <momentum/character/fwd.h>
#include <momentum/character/marker.h>
#include <momentum/common/filesystem.h>
#include <momentum/io/fbx/fbx_io.h>
#include <momentum/io/file_save_options.h>
#include <momentum/math/fwd.h>
#include <momentum/math/types.h>
#include <string>
#include <vector>

Go to the source code of this file.

Namespaces

namespace  momentum

Enumerations

enum class  momentum::CharacterFormat : uint8_t { momentum::Fbx , momentum::Gltf , momentum::Usd , momentum::Unknown }
 Represents the supported character formats. More...

Functions

Character momentum::loadFullCharacter (const std::string &characterPath, const std::string &parametersPath=std::string(), const std::string &locatorsPath=std::string(), LoadBlendShapes loadBlendShapes=LoadBlendShapes::No)
 High level function to load a character of any type, with a local path.
Character momentum::loadFullCharacterFromBuffer (CharacterFormat format, std::span< const std::byte > characterBuffer, std::span< const std::byte > paramBuffer=std::span< const std::byte >(), std::span< const std::byte > locBuffer=std::span< const std::byte >(), LoadBlendShapes loadBlendShapes=LoadBlendShapes::No)
 Buffer version of loadFullCharacter function, supports .glb and .fbx file formats.
void momentum::saveCharacter (const filesystem::path &filename, const Character &character, float fps=120.f, const MatrixXf &motion=MatrixXf(), std::span< const std::vector< Marker > > markerSequence={}, const FileSaveOptions &options=FileSaveOptions())
 High level function to save a character with motion and markers to any supported format.
void momentum::saveCharacter (const filesystem::path &filename, const Character &character, float fps, std::span< const SkeletonState > skeletonStates, std::span< const std::vector< Marker > > markerSequence={}, const FileSaveOptions &options=FileSaveOptions())
 High level function to save a character with motion in skeleton states and markers to any supported format.