X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;ds=sidebyside;f=source%2Fglsl%2Fsyntax.cpp;h=c8058c4fe9a228b102cbe4792daa83dc3f921f70;hb=e8542d921a07b7391d558cb3349a68f26675f797;hp=931578640b94fc4f874b25648dfef01fd0330c0d;hpb=a82fcc462550d63a101aca4313807b1320789a5a;p=libs%2Fgl.git diff --git a/source/glsl/syntax.cpp b/source/glsl/syntax.cpp index 93157864..c8058c4f 100644 --- a/source/glsl/syntax.cpp +++ b/source/glsl/syntax.cpp @@ -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; @@ -314,7 +347,8 @@ void InterfaceBlock::visit(NodeVisitor &visitor) FunctionDeclaration::FunctionDeclaration(): - definition(0) + definition(0), + return_type_declaration(0) { } FunctionDeclaration::FunctionDeclaration(const FunctionDeclaration &other): @@ -323,7 +357,8 @@ FunctionDeclaration::FunctionDeclaration(const FunctionDeclaration &other): name(other.name), parameters(other.parameters), body(other.body), - definition(other.definition==&other ? this : 0) + definition(other.definition==&other ? this : 0), + return_type_declaration(0) { } void FunctionDeclaration::visit(NodeVisitor &visitor)