28 lines
492 B
C++
28 lines
492 B
C++
#include <iostream>
|
|
#include <string>
|
|
#include <vector>
|
|
#include <glm/vec4.hpp>
|
|
#include "ADrawable.h"
|
|
|
|
#pragma once
|
|
class ColorCube : public ADrawable
|
|
{
|
|
private:
|
|
GLuint _vaoHandle;
|
|
GLuint _iboHandle;
|
|
GLuint _vbo_vertices, _vbo_colors, _vbo_normals;
|
|
|
|
bool ibo_used;
|
|
|
|
void iboSetup();
|
|
void vaoSetup();
|
|
|
|
public:
|
|
ColorCube(bool usingIBO);
|
|
|
|
void draw(ShaderProgram *shader, glm::mat4x4 proj_matrix, glm::mat4x4 view_matrix) override;
|
|
DrawableType getType() override;
|
|
~ColorCube();
|
|
};
|
|
|