Baked motion-matching feature database from one or more AnimClips. Feature layout per frame: [0..1] root velocity xz [2..7] trajectory pos xz at +0.33/+0.66/+1.0s (character space) [8..10] trajectory facing dir xz + yaw sin/cos packed as (fx,fz) for +1.0s [11..] selected joint world positions (xyz each) Script type: MotionDatabase.
更多...
#include <MotionDatabase.h>
类 | |
| struct | Frame |
Public 成员函数 | |
| MotionDatabase (AnimSkeleton *skeleton) | |
| ~MotionDatabase ()=default | |
| MotionDatabase (const MotionDatabase &)=delete | |
| MotionDatabase & | operator= (const MotionDatabase &)=delete |
| AnimSkeleton * | getSkeleton () const |
| void | addFeatureBone (int boneIndex) |
| Include bone world position in pose features (by index). | |
| void | addFeatureBoneByName (const std::string &name) |
| void | setRootBone (int boneIndex) |
Bone used for trajectory / velocity features (default 0). Mixamo clips typically want hips (mixamorig:Hips). | |
| int | getRootBone () const |
| void | setRootBoneByName (const std::string &name) |
| void | addClip (AnimClip *clip) |
| int | getClipCount () const |
| void | bake () |
| Bake all clips into searchable frames. Call after addClip / feature bones. | |
| bool | isBaked () const |
| int | getFrameCount () const |
| int | getFeatureSize () const |
| float | getFrameTime (int frameIndex) const |
| int | getFrameClipIndex (int frameIndex) const |
| AnimClip * | getClip (int clipIndex) const |
| int | getFeatureBoneCount () const |
| int | getFeatureBone (int index) const |
| void | getFeature (int frameIndex, float *out, int outCount) const |
| Copy feature vector into out[0..featureSize). | |
| const Frame & | frameAt (int index) const |
详细描述
Baked motion-matching feature database from one or more AnimClips. Feature layout per frame: [0..1] root velocity xz [2..7] trajectory pos xz at +0.33/+0.66/+1.0s (character space) [8..10] trajectory facing dir xz + yaw sin/cos packed as (fx,fz) for +1.0s [11..] selected joint world positions (xyz each) Script type: MotionDatabase.
在文件 MotionDatabase.h 第 22 行定义.
构造及析构函数说明
◆ MotionDatabase() [1/2]
|
explicit |
◆ ~MotionDatabase()
|
default |
◆ MotionDatabase() [2/2]
|
delete |
成员函数说明
◆ addClip()
| void eve::animation::MotionDatabase::addClip | ( | AnimClip * | clip | ) |
在文件 MotionDatabase.cpp 第 48 行定义.
◆ addFeatureBone()
| void eve::animation::MotionDatabase::addFeatureBone | ( | int | boneIndex | ) |
Include bone world position in pose features (by index).
在文件 MotionDatabase.cpp 第 17 行定义.
引用了 b , 以及 eve::animation::AnimSkeleton::getBoneCount().
被这些函数引用 addFeatureBoneByName() , 以及 bake().
◆ addFeatureBoneByName()
| void eve::animation::MotionDatabase::addFeatureBoneByName | ( | const std::string & | name | ) |
在文件 MotionDatabase.cpp 第 28 行定义.
引用了 addFeatureBone(), eve::animation::AnimSkeleton::findBone() , 以及 name.
◆ bake()
| void eve::animation::MotionDatabase::bake | ( | ) |
Bake all clips into searchable frames. Call after addClip / feature bones.
在文件 MotionDatabase.cpp 第 153 行定义.
引用了 addFeatureBone(), eve::animation::MotionDatabase::Frame::clipIndex, f, eve::animation::AnimSkeleton::getBoneCount(), getClipCount(), eve::animation::AnimClip::getDuration() , 以及 eve::animation::AnimClip::getSampleRate().
◆ frameAt()
| const MotionDatabase::Frame & eve::animation::MotionDatabase::frameAt | ( | int | index | ) | const |
在文件 MotionDatabase.cpp 第 191 行定义.
引用了 getFrameCount().
被这些函数引用 getFeature(), getFrameClipIndex(), getFrameTime() , 以及 eve::animation::MotionMatcher::search().
◆ getClip()
| AnimClip * eve::animation::MotionDatabase::getClip | ( | int | clipIndex | ) | const |
在文件 MotionDatabase.cpp 第 54 行定义.
引用了 getClipCount().
◆ getClipCount()
|
inline |
在文件 MotionDatabase.h 第 45 行定义.
◆ getFeature()
| void eve::animation::MotionDatabase::getFeature | ( | int | frameIndex, |
| float * | out, | ||
| int | outCount | ||
| ) | const |
Copy feature vector into out[0..featureSize).
在文件 MotionDatabase.cpp 第 205 行定义.
◆ getFeatureBone()
| int eve::animation::MotionDatabase::getFeatureBone | ( | int | index | ) | const |
在文件 MotionDatabase.cpp 第 71 行定义.
◆ getFeatureBoneCount()
|
inline |
在文件 MotionDatabase.h 第 58 行定义.
被这些函数引用 getFeatureBone().
◆ getFeatureSize()
|
inline |
在文件 MotionDatabase.h 第 52 行定义.
◆ getFrameClipIndex()
| int eve::animation::MotionDatabase::getFrameClipIndex | ( | int | frameIndex | ) | const |
◆ getFrameCount()
|
inline |
在文件 MotionDatabase.h 第 51 行定义.
被这些函数引用 frameAt() , 以及 eve::animation::MotionMatcher::search().
◆ getFrameTime()
| float eve::animation::MotionDatabase::getFrameTime | ( | int | frameIndex | ) | const |
在文件 MotionDatabase.cpp 第 199 行定义.
引用了 frameAt() , 以及 eve::animation::MotionDatabase::Frame::time.
◆ getRootBone()
|
inline |
在文件 MotionDatabase.h 第 41 行定义.
◆ getSkeleton()
|
inline |
在文件 MotionDatabase.h 第 30 行定义.
◆ isBaked()
|
inline |
在文件 MotionDatabase.h 第 49 行定义.
被这些函数引用 eve::animation::MotionMatcher::search() , 以及 eve::animation::MotionMatcher::update().
◆ operator=()
|
delete |
◆ setRootBone()
| void eve::animation::MotionDatabase::setRootBone | ( | int | boneIndex | ) |
Bone used for trajectory / velocity features (default 0). Mixamo clips typically want hips (mixamorig:Hips).
在文件 MotionDatabase.cpp 第 34 行定义.
引用了 eve::animation::AnimSkeleton::getBoneCount().
被这些函数引用 setRootBoneByName().
◆ setRootBoneByName()
| void eve::animation::MotionDatabase::setRootBoneByName | ( | const std::string & | name | ) |
在文件 MotionDatabase.cpp 第 42 行定义.
引用了 eve::animation::AnimSkeleton::findBone(), name , 以及 setRootBone().
该类的文档由以下文件生成:
- src/modules/animation/MotionDatabase.h
- src/modules/animation/MotionDatabase.cpp