animation interface

This commit is contained in:
devZoGok
2021-10-19 19:06:41 +03:00
parent 413272e516
commit f0c88291ec
2 changed files with 9 additions and 1 deletions
+5
View File
@@ -199,4 +199,9 @@ namespace vb01{
glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
glDrawElementsInstanced(GL_TRIANGLES, 6, GL_UNSIGNED_INT, 0, numParticles);
}
void ParticleEmitter::animate(float value, KeyframeChannel keyframeChannel){
switch(keyframeChannel.type){
}
}
}
+4 -1
View File
@@ -3,6 +3,8 @@
#include "vector.h"
#include "util.h"
#include "animatable.h"
#include <glm.hpp>
namespace vb01{
@@ -10,7 +12,7 @@ namespace vb01{
class Node;
class Material;
class ParticleEmitter{
class ParticleEmitter : public Animatable{
public:
ParticleEmitter(){}
ParticleEmitter(int);
@@ -46,6 +48,7 @@ namespace vb01{
void setupParticles(Vertex[]);
void setupDisplay(Vertex[], u32[]);
void render();
void animate(float, KeyframeChannel);
u32 VAO, VBO, EBO, MBO;
glm::mat4 *matrices;