]> git.tdb.fi Git - libs/gl.git/blobdiff - source/glsl/syntax.cpp
Give declaration nodes to all GLSL types.
[libs/gl.git] / source / glsl / syntax.cpp
index 931578640b94fc4f874b25648dfef01fd0330c0d..e20d6c262eae2525a0a979922c800e9956f39f18 100644 (file)
@@ -237,6 +237,39 @@ void InterfaceLayout::visit(NodeVisitor &visitor)
 }
 
 
+BasicTypeDeclaration::BasicTypeDeclaration():
+       kind(ALIAS),
+       size(0),
+       base_type(0)
+{ }
+
+BasicTypeDeclaration::BasicTypeDeclaration(const BasicTypeDeclaration &other):
+       TypeDeclaration(other),
+       kind(other.kind),
+       size(other.size),
+       base(other.base),
+       base_type(0)
+{ }
+
+void BasicTypeDeclaration::visit(NodeVisitor &visitor)
+{
+       visitor.visit(*this);
+}
+
+
+ImageTypeDeclaration::ImageTypeDeclaration():
+       dimensions(TWO),
+       array(false),
+       sampled(true),
+       shadow(false)
+{ }
+
+void ImageTypeDeclaration::visit(NodeVisitor &visitor)
+{
+       visitor.visit(*this);
+}
+
+
 StructDeclaration::StructDeclaration()
 {
        members.use_braces = true;