Reflection
[opengl.git] / model.hpp
index de8e27f8639f8c422de78127faa300ec15b4fd45..e0c8a2d93acd0a4e7fedcd542bcc4a36cb1746a9 100644 (file)
--- a/model.hpp
+++ b/model.hpp
@@ -9,6 +9,7 @@
 #include <assimp/Importer.hpp>
 #include "material.hpp"
 #include "program.hpp"
+#include "skybox.hpp"
 
 class Model {
 
@@ -19,13 +20,13 @@ class Model {
        };
        
        public:
-               Model(const std::string &path, Program p);
+               Model(const std::string &path, Program p, Skybox s);
                void draw() const;
 
                class Node {
                        public:
                                Node(const aiNode &aiNode, GLuint progId);
-                               void draw(const std::vector<Mesh> &meshes, const std::vector<Material> &materials, glm::mat4 parentModel) const;
+                               void draw(const std::vector<Mesh> &meshes, const std::vector<Material> &materials, const Skybox s, glm::mat4 parentModel) const;
                                const std::vector<Node*> &getChildren() const { return children; }
                                Node* findNode(const aiNode &aiNode);
                                glm::mat4 model = glm::mat4(1);
@@ -42,6 +43,7 @@ class Model {
        
        private:
                const Program program;
+               const Skybox skybox;
                
                std::vector<Mesh> meshes;
                Node *root;