1#ifndef PGR_SEM_COPAKOND_MESH_H
2#define PGR_SEM_COPAKOND_MESH_H
33 std::vector<float>
_vertices = std::vector<float>();
34 std::shared_ptr<Material>
_material = std::make_shared<Material>();
46 void setVertices(
const std::vector<float> &vertices);
49 void setMaterial(
const std::shared_ptr<Material> &material);
61 virtual void draw(
float deltaTime);
glm::vec3 & rotation()
Definition geometry.h:61
Geometry()
Definition geometry.cpp:4
glm::vec3 & scale()
Definition geometry.h:62
glm::vec3 & position()
Definition geometry.h:60
GLuint _shaderProgram
Definition mesh.h:26
void hide()
Definition mesh.h:67
int _isVertexWave
Definition mesh.h:23
std::vector< SubMesh > _subMeshes
Definition mesh.h:35
std::shared_ptr< Material > getMaterial()
Definition mesh.cpp:36
bool _visible
Definition mesh.h:24
void setVertices(const std::vector< float > &vertices)
Definition mesh.cpp:26
std::shared_ptr< Material > _material
Definition mesh.h:34
GLuint _vboNormals
Definition mesh.h:28
GLuint _vao
Definition mesh.h:29
const std::vector< SubMesh > & getSubMeshes() const
Definition mesh.h:50
void show()
Definition mesh.h:68
int id
Definition mesh.h:22
GLuint getVao() const
Definition mesh.h:53
GLuint _vboVertices
Definition mesh.h:27
bool isVertexWave() const
Definition mesh.h:65
int getId() const
Definition mesh.h:62
static int globalMeshCounter
Definition mesh.h:21
bool isVisible() const
Definition mesh.h:70
virtual ~Mesh()
Definition mesh.cpp:20
void setMaterial(const std::shared_ptr< Material > &material)
Applies a material to the entire mesh and all its submeshes.
Definition mesh.cpp:30
void setVertexWave(bool isVertexWave)
Definition mesh.h:64
GLsizei _numVertices
Definition mesh.h:31
void setVisible(bool visible)
Definition mesh.h:69
GLsizei getNumVertices() const
Definition mesh.h:54
Mesh()
Definition mesh.cpp:12
std::vector< float > _vertices
Definition mesh.h:33
void _SetId()
Definition mesh.cpp:8
PGR Semestral work with sample scenes and bowling. doxygen was generated with a help of LLM.
Definition bezier.cpp:3
Shader * shader
Definition main.cpp:37
void init()
Initializes OpenGL context, scene data, and sets up GLUT callbacks.
Definition main.cpp:42
void draw()
Main render loop. Handles updates, physics, and rendering of all scene elements.
Definition main.cpp:97
Represents a part of a mesh that uses a specific material.
Definition mesh.h:12
unsigned int indexOffset
Definition mesh.h:14
unsigned int indexCount
Definition mesh.h:15
std::shared_ptr< Material > material
Definition mesh.h:13