feat(shape)!: add shape super class

This commit is contained in:
2025-12-09 20:05:07 +01:00
parent b8a0cdfa3e
commit bcc999e4a7

31
inc/shape.hpp Normal file
View File

@@ -0,0 +1,31 @@
#ifndef SHAPE_HPP
#define SHAPE_HPP
#include <stddef.h>
#include <mutex>
#include "camera.hpp"
#include "glm/fwd.hpp"
class Shape
{
protected:
glm::vec3 position;
Camera& cameraRef;
virtual void init() = 0;
public:
Shape(Camera& cameraRef, glm::vec3 position)
: position(position), cameraRef(cameraRef)
{
}
glm::vec3 getPosition() const { return position; }
Camera& getCamera() const { return cameraRef; }
virtual void render() = 0;
};
#endif