projects
/
opengl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Implement IBL diffuse part
[opengl.git]
/
skybox.hpp
diff --git
a/skybox.hpp
b/skybox.hpp
index f1ac4ee9a19c2ab3bab08440c496e49515855756..40ed1a1b4c058e6ae13c41df0f58dc66ae84d79d 100644
(file)
--- a/
skybox.hpp
+++ b/
skybox.hpp
@@
-1,13
+1,23
@@
+#ifndef SKYBOX_HPP
+#define SKYBOX_HPP
+
#include <string>
#include <vector>
#include <GL/glew.h>
#include <glm/glm.hpp>
#include "program.hpp"
#include <string>
#include <vector>
#include <GL/glew.h>
#include <glm/glm.hpp>
#include "program.hpp"
+#include "image.hpp"
class Skybox {
public:
class Skybox {
public:
- Skybox(const std::vector<std::string> faces);
+ // img must be HDR
+ Skybox(const Image img);
void draw(glm::mat4 proj, glm::mat4 view) const;
void draw(glm::mat4 proj, glm::mat4 view) const;
+ GLuint getTexture() const { return cubemapTexId; }
+ GLuint getIrradianceMap() const { return irradianceTexId; }
private:
private:
- GLuint texId, vao;
+ GLuint hdrTexId, cubemapTexId, irradianceTexId;
+ GLuint vao;
const Program program;
};
const Program program;
};
+
+#endif