Skip to content

Commit

Permalink
Update documentation of CharacterParameters
Browse files Browse the repository at this point in the history
Summary: No-op change

Reviewed By: yutingye

Differential Revision: D63541460

fbshipit-source-id: 8fd4d5312604a35502da8d78dad35ee59e60785c
  • Loading branch information
jeongseok-meta authored and facebook-github-bot committed Sep 28, 2024
1 parent 88fcf34 commit 5780aa2
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 4 deletions.
6 changes: 6 additions & 0 deletions momentum/character/parameter_transform.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,28 +61,34 @@ template <typename T>
struct ParameterTransformT {
/// The list of model parameter names.
std::vector<std::string> name;

/// The sparse mapping matrix that maps model parameters to joint parameters.
SparseRowMatrix<T> transform;

/// @deprecated Constant offset factor for each joint.
Eigen::VectorX<T> offsets;

/// The list of joint *parameters* that are actually active and influenced from the transform.
VectorX<bool> activeJointParams;

/// Convenience grouping of model parameters.
ParameterSets parameterSets;

/// A set of predefined poses.
PoseConstraints poseConstraints;

/// The indices of the parameters that influence blend shapes; blendShapeParameters(0) is the
/// parameter that controls the 0th blend shape, etc.
VectorXi blendShapeParameters;

/// The indices of the parameters that influence face expressions; faceExpressionParameters(0) is
/// the parameter that controls the 0th face expression parameter, etc.
VectorXi faceExpressionParameters;

/// Return a ParameterTransform object with no model parameters. The model can still perform FK
/// with JointParameters, but it does not have any degrees of freedom for IK.
static ParameterTransformT<T> empty(size_t nJointParameters);

/// Return a ParameterTransform object where the model parameters are identical to the joint
/// parameters.
static ParameterTransformT<T> identity(gsl::span<const std::string> jointNames);
Expand Down
15 changes: 11 additions & 4 deletions momentum/character/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -163,13 +163,20 @@ using JointStateListT = std::vector<JointStateT<T>>;
using JointStateList = JointStateListT<float>;
using JointStateListd = JointStateListT<double>;

// A struct containing the joint parameters that describe a pose + offsets for
// a parameter transform
/// A struct that encapsulates both pose and identity parameters for a character.
///
/// @note This structure implies, but does not enforce, that the pose vector should contain only
/// pose information with identity-related elements set to zero. Similarly, the identity vector
/// should exclusively contain bone length information, excluding any pose data.
template <typename T>
struct CharacterParametersT {
// A model parameter pose vector of size numModelParams
/// The model parameter vector representing the pose of the character. This vector should have a
/// size of numModelParams.

ModelParametersT<T> pose;
// Joint parameter offset vector of size numSkeletonJoints * kParametersPerJoint
/// The joint parameter vector representing the unique bone lengths of the character, defining
/// the character's identity. This vector should have a size of numSkeletonJoints *
/// kParametersPerJoint.
JointParametersT<T> offsets;
};

Expand Down

0 comments on commit 5780aa2

Please sign in to comment.