]> git.tdb.fi Git - libs/gl.git/blobdiff - source/glsl/syntax.h
Reduce coupling between the GLSL compiler and the graphics engine
[libs/gl.git] / source / glsl / syntax.h
index 05bcee545f4a62431ddf8c00978d766e6c670565..3fb848d2ceb81a91fdc07ab19f0e072b0b71010c 100644 (file)
@@ -6,9 +6,8 @@
 #include <string>
 #include <vector>
 #include <msp/core/refptr.h>
-#include "extension.h"
+#include "features.h"
 #include "sourcemap.h"
-#include "uniform.h"
 
 #pragma push_macro("interface")
 #undef interface
@@ -107,10 +106,13 @@ struct Block: Node
 {
        NodeList<Statement> body;
        bool use_braces;
+       bool anonymous;
        std::map<std::string, StructDeclaration *> types;
        std::map<std::string, VariableDeclaration *> variables;
+       Block *parent;
 
        Block();
+       Block(const Block &);
 
        virtual Block *clone() const { return new Block(*this); }
        virtual void visit(NodeVisitor &);
@@ -384,8 +386,7 @@ struct Stage
        std::map<std::string, VariableDeclaration *> in_variables;
        std::map<std::string, VariableDeclaration *> out_variables;
        std::map<std::string, unsigned> locations;
-       Version required_version;
-       std::vector<const Extension *> required_extensions;
+       Features required_features;
 
        Stage(Type);