c-project/include/skyBox.h

31 lines
466 B
C
Raw Permalink Normal View History

2024-05-15 12:04:44 +02:00
#pragma once
#include <glad/glad.h>
#include <shader.h>
#include <glm/mat4x4.hpp>
class SkyBox
{
public:
void create();
void clear();
void clearTexture();
void loadTextures(const char *textures[]);
void loadTexturesFromCrossTexture(const char* texture);
void render(const glm::mat4 &viewProjection);
private:
GLuint cubemapTexture = 0;
Shader shader;
GLint u_cubeMap = -1;
GLint u_viewProjection = -1;
GLuint vao = 0;
GLuint cubeBuffer = 0;
};