X-Git-Url: https://git.lukelau.me/?p=opengl.git;a=blobdiff_plain;f=skybox.hpp;h=6961e8d861104d82843739e28978e399b7104d12;hp=0b523758a89f2c0d755e848975eb53f35c793c3f;hb=d0c631f46c6db417e013b1bc0edec24cb9c2824a;hpb=a03f2bc751bbd7f91cbc2f52d2f0f6e753d6f776 diff --git a/skybox.hpp b/skybox.hpp index 0b52375..6961e8d 100644 --- a/skybox.hpp +++ b/skybox.hpp @@ -12,10 +12,17 @@ class Skybox { // img must be HDR Skybox(const Image img); void draw(glm::mat4 proj, glm::mat4 view) const; - GLuint getTexture() const; + GLuint getTexture() const { return cubemapTexId; } + GLuint getIrradianceMap() const { return irradianceTexId; } + GLuint getPrefilterMap() const { return prefilterTexId; } + GLuint getBRDFMap() const { return brdfMapTexId; } private: - GLuint texId, vao; + GLuint hdrTexId, cubemapTexId, irradianceTexId, prefilterTexId, brdfMapTexId; + GLuint captureFBO, captureRBO; + GLuint vao; const Program program; + void generatePrefilterMap() const; + void generateBRDFMap() const; }; #endif