added placeholder componenets

This commit is contained in:
OusmBlueNinja 2024-12-25 17:58:56 -06:00
parent bf6df61f88
commit 0c7fd361f0
3 changed files with 37 additions and 0 deletions

View File

@ -0,0 +1,11 @@
// GameObject.h
#pragma once
#include "Transform.h"
#include "Mesh.h"
// A game object that has a transform and a mesh
struct GameObject
{
Transform transform;
Mesh mesh;
};

12
src/Componenets/Mesh.h Normal file
View File

@ -0,0 +1,12 @@
// Mesh.h
#pragma once
#include <GL/glew.h>
// A simple mesh storing a VAO, index count, and texture ID
struct Mesh
{
GLuint vao = 0; // Vertex Array Object
GLuint indexCount = 0; // Number of indices to draw
GLuint textureID = 0; // The texture handle
};

View File

@ -0,0 +1,14 @@
// Transform.h
#pragma once
#include <glm/glm.hpp>
// A simple transform with position, rotation, scale
struct Transform
{
glm::vec3 position {0.f, 0.f, 0.f};
glm::vec3 rotation {0.f, 0.f, 0.f}; // Euler angles, in degrees or radians
glm::vec3 scale {1.f, 1.f, 1.f};
};