35 lines
732 B
C++
35 lines
732 B
C++
//
|
|
// Created by martin on 12.11.21.
|
|
//
|
|
|
|
#ifndef ANIMTESTBED_ANIMNODE_H
|
|
#define ANIMTESTBED_ANIMNODE_H
|
|
|
|
#include <string>
|
|
|
|
#include "AnimationController.h"
|
|
|
|
struct AnimNode {
|
|
AnimNode(AnimationController* animation_controller) : m_animation_controller(animation_controller) {}
|
|
virtual ~AnimNode() {};
|
|
|
|
std::string m_name;
|
|
float m_current_time;
|
|
AnimationController* m_animation_controller;
|
|
ozz::vector<ozz::math::SoaTransform> m_local_matrices;
|
|
|
|
virtual void Reset() {
|
|
m_current_time = 0.f;
|
|
}
|
|
|
|
virtual void Update(float dt) {
|
|
m_current_time += dt;
|
|
}
|
|
|
|
virtual void Evaluate(ozz::vector<ozz::math::SoaTransform>* local_matrices) = 0;
|
|
|
|
virtual void DrawDebugUi() {};
|
|
};
|
|
|
|
#endif //ANIMTESTBED_ANIMNODE_H
|