]> git.tdb.fi Git - libs/gl.git/blobdiff - source/program.h
Fix the keyword of the uniform scaling statement in Transform loader
[libs/gl.git] / source / program.h
index 4feb862d29483cf99359e52750d671726e1175ef..cbb52cd4536e93bd0b2cd65c0f9868cfe946b1f5 100644 (file)
@@ -1,8 +1,8 @@
 #ifndef MSP_GL_PROGRAM_H_
 #define MSP_GL_PROGRAM_H_
 
-#include <list>
 #include <string>
+#include <vector>
 #include <msp/datafile/objectloader.h>
 #include "bindable.h"
 #include "gl.h"
@@ -31,6 +31,7 @@ public:
 
                void attribute(unsigned, const std::string &);
                void fragment_shader(const std::string &);
+               void geometry_shader(const std::string &);
                void standard();
                void vertex_shader(const std::string &);
        };
@@ -58,7 +59,7 @@ public:
                LayoutHash layout_hash;
        };
 
-       typedef std::list<Shader *> ShaderList;
+       typedef std::vector<Shader *> ShaderList;
        typedef std::map<std::string, UniformInfo> UniformMap;
        typedef std::map<std::string, UniformBlockInfo> UniformBlockMap;
 
@@ -79,6 +80,9 @@ public:
        /// Constructs a Program with standard features.
        Program(const ProgramBuilder::StandardFeatures &);
 
+       /// Constructs a Program from unified source code using ProgramCompiler.
+       Program(const std::string &);
+
        /// Constructs a Program from vertex and fragment shader source code.
        Program(const std::string &, const std::string &);
 
@@ -90,7 +94,7 @@ public:
        void attach_shader(Shader &shader);
        void attach_shader_owned(Shader *shader);
        void detach_shader(Shader &shader);
-       const ShaderList &get_shaders() const { return shaders; }
+       const ShaderList &get_attached_shaders() const { return shaders; }
 
        void bind_attribute(unsigned, const std::string &);
        void bind_attribute(VertexComponent, const std::string &);