14GX_MOTION_NAMESPACE_BEGIN()
53 constexpr f32
getFrame(
void)
const {
return _frame; }
190 b32 initialize(
const void* pAddress,
const u32 jointCount)
override;
215 constexpr f32 getFrameMax(
void)
const {
return static_cast<f32
>(_frameCount) - 1.f; }
217 void computeCurvesValuesBegin(
void);
219 void computeCurvesValuesEnd(s32 end = 0);
222 b32 computeCurvesValues(f32 frame, s32 end = 0);
224 b32 computeCurvesValues(f32 frame, s32 end = 0);
232 GxMotionCurve* _pMotionCurvesArray;
233 s32 _functionCurveCount;
272 void setFrame(u32 jointIndex, u32 frame);
336 b32 initialize(
const void* pAddress,
const u32 jointCount)
override;
341 void checkUncompress(
const void* pAddress,
const u32 jointCount,
const b32 uncompressNow);
362 f32 getCurvesValue(s32 jointIndex,u32 channelIndex,f32 frame)
const;
364 f32 getCurvesValueRotate(s32 jointIndex, u32 axis, f32 frame)
const;
366 f32 getCurvesValue(f32* pJointValues, u32 channelIndex, f32 frame)
const;
370 f32 getCurvesValueRotateWithoutDecode(s32 jointIndex, u32 axis, f32 frame)
const;
372 f32 getCurvesValueWithoutDecode( s32 jointIndex,u32 channelIndex,f32 frame,
b32 cache);
374 void getQuaternionValueWithoutDecode(s32 jointIndex, f32 frame, f32 quaternion[4],
b32 cache);
377 void uncompressJoint(s32 targetJointIndex, u32*& pAddressU32, u32& index, f32* pUncompressedData);
379 void uncompressJointFrame(s32 targetJointIndex, u32 frame0, u32 frame1, f32* pUncompressedData,
b32 skipsRotation =
false);
381 void initializeCache(u32 jointCount, u32* pAddress);
393 u32** _ppMotionRawDataStart;
397 b32 _enableLinearInterpolation;
403GX_MOTION_NAMESPACE_END()
#define GX_PROHIBIT_CLASS_BASE(__CLASS__)
GxClassBase継承の禁止宣言
Definition GxBase.h:240
オブジェクト基底クラス
Definition GxBase.h:88
モーションの曲線関数を管理するクラス(オイラーベース)
Definition GxMotionCurvesContainer.h:78
MOTION_DATA
GMPファイル中のデータアクセス用定義
Definition GxMotionCurvesContainer.h:111
@ LOCATOR_TRANSLATE_Y
rot_yの座標
@ LOCATOR_ROTATE_Y
モーションデータの始めはrot_yの角度
GX_FORCE_INLINE f32 getMotionTranslateY(void) override
rot_y関節の移動値を取得
Definition GxMotionCurvesContainer.h:210
GX_FORCE_INLINE f32 getMotionRotateY(void) override
rot_y関節の回転値を取得
Definition GxMotionCurvesContainer.h:208
~GxMotionCurvesContainerEuler(void) override
デストラクタ
Definition GxMotionCurvesContainer.cpp:112
constexpr f32 const * getCurrentValuesArray(void) const
格カーブの現在の値の行列を取得
Definition GxMotionCurvesContainer.h:206
void setFrame(f32 frame) override
現在のフレームを設定
Definition GxMotionCurvesContainer.cpp:277
FUNCTION_CURVE
曲線関数の種類
Definition GxMotionCurvesContainer.h:97
@ SPLINE_EXIST
データカーブがあるカーブ
@ DATA_MASK
3bitマスク [0111]
@ STATIC_ONE_HALF_PI
1.5πのカーブ
@ STATIC_BASEPOSE
ベースポーズと同じのカーブ
@ SPLINE_DATA
値のカーブデータもスロープデータもあるカーブ
@ SPLINE_SLOPE_0
値のカーブデータがあるが、スロープデータがないカーブ
constexpr void setFrameWithoutComputeCurves(f32 frame)
現在のフレームを設定(カーブ情報の再計算は行いません)
Definition GxMotionCurvesContainer.h:204
static const f32 STATIC_VALUE_TABLE[static_cast< s32 >(FUNCTION_CURVE::STATIC_DATA)]
静的値テーブル
Definition GxMotionCurvesContainer.h:90
GxMotionCurvesContainerEuler(void)
デフォルトコンストラクタ
Definition GxMotionCurvesContainer.cpp:102
static const f32 FLOAT_MAX
固定値:GxModMotionDataPlayerに、ベースポーズを使いたいと伝えたい時
Definition GxMotionCurvesContainer.h:92
b32 initialize(const void *pAddress, const u32 jointCount) override
初期化
Definition GxMotionCurvesContainer.cpp:127
static constexpr u32 MOTION_DATA_COMPONENT_COUNT
モーションデータ種類の数:スケール+回転+位置
Definition GxMotionCurvesContainer.h:94
constexpr s32 getFunctionCurveCount(void) const
カーブ数を取得
Definition GxMotionCurvesContainer.h:212
モーションの曲線関数を管理するクラス(インターフェイス)
Definition GxMotionCurvesContainer.h:20
f32 * _pMotionCurvesCurrentValuesArray
各カーブの現在の値の行列
Definition GxMotionCurvesContainer.h:67
f32 _frame
現在のフレーム
Definition GxMotionCurvesContainer.h:68
virtual f32 getMotionRotateY(void)=0
rot_y関節の回転値を取得
virtual b32 initialize(const void *pAddress, const u32 jointCount)=0
初期化
constexpr f32 getFrame(void) const
現在のフレームを取得
Definition GxMotionCurvesContainer.h:53
virtual void setFrame(f32 frame)=0
現在のフレームを設定
~GxMotionCurvesContainer(void) override
デストラクタ
Definition GxMotionCurvesContainer.h:42
virtual f32 getMotionTranslateY(void)=0
rot_y関節の移動値を取得
モーションの曲線関数を管理するクラス(クォータニオンベース)
Definition GxMotionCurvesContainer.h:297
~GxMotionCurvesContainerQuaternion(void) override
デストラクタ
Definition GxMotionCurvesContainer.cpp:503
b32 computeCurvesValues(s32 jointIndex, u32 jointCount, GxVector3 &translate, GxQuaternion &quaternion, GxVector3 &scale)
各チャンネルの現フレームの値を計算し_pMotionCurvesCurrentValuesArray行列に保存
Definition GxMotionCurvesContainer.cpp:1193
b32 initialize(const void *pAddress, const u32 jointCount) override
初期化(旧型式との互換性のため)
Definition GxMotionCurvesContainer.cpp:520
void setEnableLinearInterpolation(b32 enable)
フレーム間線形補間の有効設定
Definition GxMotionCurvesContainer.cpp:981
f32 getMotionTranslateY(void) override
rot_y関節の移動値を取得
Definition GxMotionCurvesContainer.cpp:1132
GxMotionCurvesContainerQuaternion(void)
デフォルトコンストラクタ
Definition GxMotionCurvesContainer.cpp:486
void setFrame(f32 frame) override
現在のフレームを設定
Definition GxMotionCurvesContainer.cpp:972
static constexpr u32 NUM_CHANNEL
transXYZ・rotateXYZW・scaleXYZ
Definition GxMotionCurvesContainer.h:311
static constexpr u32 NUM_CHANNEL_ROTATE
rotateXYZW
Definition GxMotionCurvesContainer.h:313
f32 getMotionRotateY(void) override
rot_y関節の回転値を取得
Definition GxMotionCurvesContainer.cpp:1044
DECODE_TYPE
モーションデータ展開のタイプ
Definition GxMotionCurvesContainer.h:317
@ INITIALIZE_WITHOUT_DECODE
INIT_NONEでのデコード用の一時バッファーを使わない実装
@ INITIALIZE_NONE
メモリ小、計算大。毎フレーム展開。
@ INITIALIZE_WITHOUT_DECODE_CACHE
INIT_NONEでのデコード用の一時バッファーを使わない実装
@ INITIALIZE_ROTATE
メモリ中、計算中。initialize()でrotateのみ展開。
@ INITIALIZE_ALL
メモリ大、計算小。initialize()ですべて展開。
キーキャッシュクラス
Definition GxMotionEncoder.h:21
モーションキャッシュクラス
Definition GxMotionCurvesContainer.h:242
void initialize(u32 jointCount)
初期化
Definition GxMotionCurvesContainer.cpp:1479
KeyCache * getKeyCache(u32 jointIndex, u32 channelIndex)
キーキャッシュを取得
Definition GxMotionCurvesContainer.cpp:1501
void release(void)
解放処理
Definition GxMotionCurvesContainer.cpp:1459
~MotionCache(void)
デストラクタ
Definition GxMotionCurvesContainer.cpp:1470
jointCache * getJointCache(u32 jointIndex)
関節キャッシュを取得
Definition GxMotionCurvesContainer.cpp:1490
void setFrame(u32 jointIndex, u32 frame)
フレームを設定
Definition GxMotionCurvesContainer.cpp:1450
u32 getFrame(u32 jointIndex)
フレームを取得
Definition GxMotionCurvesContainer.cpp:1439
MotionCache(void)
デフォルトコンストラクタ
Definition GxMotionCurvesContainer.h:257
関節情報のキャッシュ
Definition GxMotionCurvesContainer.cpp:18
モーションカーブクラス
Definition GxMotionCurvesContainer.h:121
void const * _pKeyFramesArray
キーフレームの行列 - X-values (some keyFrames might have been skipped) [if(_frameCount)<256 _pKeyFramesArray i...
Definition GxMotionCurvesContainer.h:174
f32 const * _pValuesArray
値の行列(_frameCountが256を超える場合はu16、超えない場合はu8) - Y-values - contains also slopes if _kind == FUNCTION_CURV...
Definition GxMotionCurvesContainer.h:173
void getCurveSlope(void *pValue, u32 index)
カーブスロープを取得
void setDummyCount(u32)
ダミー数を設定
Definition GxMotionCurvesContainer.h:160
void getCurveKeyFrame(void *pValue, u32 index)
カーブキーフレームを取得
u32 getCurveSlopeCount(void)
カーブスロープ数を取得
s32 _keyFramesCount
キーフレーム数(最初beginValueと最後endValueフレームを除く)
Definition GxMotionCurvesContainer.h:171
GxMotionCurve(void)
デフォルトコンストラクタ
Definition GxMotionCurvesContainer.cpp:67
FUNCTION_CURVE _kind
カーブ種類
Definition GxMotionCurvesContainer.h:170
void getCurveValue(void *pValue, u32 index)
カーブ値を取得
constexpr void setDummyValue(const void *, u32)
ダミー値を設定
Definition GxMotionCurvesContainer.h:162
s32 _currentKeyFrame
現在のキーフレーム - (reset to 0 in GxMotionCurvesContainer::initialize, used to keep track of previous value,...
Definition GxMotionCurvesContainer.h:172
u32 getCurveKeyFrameCount(void)
カーブキーフレーム数を取得
u32 getCurveValueCount(void)
カーブ値数を取得
クォータニオン
Definition GxQuaternion.h:19
3次元ベクトル
Definition GxVector.h:245
32bitブーリアン
Definition GxDefine.h:173