rodecomp/Source/Contents/Models/ModelAnimation.h
ragnarok-clanker a70bbfd840 Decompile fn_17482 (C3dNodeV1::Initialize)
Batch #17684 by eAthena: 0 byte-identical, 1 confirmed by peer review.

- fn_17482 C3dNodeV1::Initialize: logic confirmed by peer review

Peer-reviewed-by: Yommy, cremane, bibinir
Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes).
2026-11-12 02:08:16 +00:00

49 lines
1.7 KiB
C++

#ifndef RAGNAROK_SOURCE_CONTENTS_MODELS_MODELANIMATION_H
#define RAGNAROK_SOURCE_CONTENTS_MODELS_MODELANIMATION_H
#include "Resource/Models/ModelResource.h"
#include "Utility/Math/AffineMatrix.h"
#include <vector>
class LegacyPositionTrack : public std::vector<ModelPositionKey> {
public:
using std::vector<ModelPositionKey>::operator=;
void Sample(int frame, matrix& output) const;
};
class LegacyRotationTrack : public std::vector<ModelRotationKey> {
public:
using std::vector<ModelRotationKey>::operator=;
void Add(int frame, float x, float y, float z, float angle);
void Sample(int frame, matrix& output) const;
};
class LegacyScaleTrack : public std::vector<ModelScaleKey> {
public:
using std::vector<ModelScaleKey>::operator=;
void Add(int frame, float scaleX, float scaleY, float scaleZ, float x, float y, float z, float angle);
void Sample(int frame, matrix& output) const;
};
class ModelScaleTrack : public std::vector<ModelRotationKey> {
public:
using std::vector<ModelRotationKey>::operator=;
void Sample(float frame, matrix& output) const;
};
class ModelPositionTrack : public std::vector<ModelRotationKey> {
public:
using std::vector<ModelRotationKey>::operator=;
void Sample(float frame, const matrix& base, matrix& output) const;
};
class ModelRotationTrack : public std::vector<ModelRotationKey> {
public:
using std::vector<ModelRotationKey>::operator=;
void Sample(float frame, const matrix& base, matrix& output) const;
};
void QuaternionMatrix(const ModelRotationKey& key, matrix& output);
void InterpolateModelRotation(float amount, const ModelRotationKey& first, const ModelRotationKey& second, int spins, ModelRotationKey& output);
#endif