X-Git-Url: http://git.tdb.fi/?p=libs%2Fgl.git;a=blobdiff_plain;f=source%2Fprogrambuilder.h;h=69170e02ef979f543b16f1fc53ef0c9adbc0c2d1;hp=821907d5dba46a281323c3364e1b85095426296e;hb=d542522823423f9ed2a5d412de9250ee8367334b;hpb=cb2281586d0202dfe2c8c181afc9cbf1d250cf25 diff --git a/source/programbuilder.h b/source/programbuilder.h index 821907d5..69170e02 100644 --- a/source/programbuilder.h +++ b/source/programbuilder.h @@ -54,6 +54,15 @@ private: FRAGMENT }; + enum InterfaceFlags + { + NO_INTERFACE = 0, + INPUT = 1, + OUTPUT = 2, + PASSTHROUGH = INPUT|OUTPUT, + GOAL = 4 + }; + struct VariableDefinition { VariableScope scope; @@ -84,6 +93,7 @@ private: void update_reference(ShaderVariable &, ShaderVariable &); void check_inline(bool, bool); bool is_referenced_from(VariableScope) const; + InterfaceFlags get_interface_flags(VariableScope) const; std::string create_declaration(char = 0) const; std::string create_replacement(VariableScope) const; std::string create_expression() const; @@ -102,6 +112,7 @@ private: bool optimize; static const VariableDefinition standard_variables[]; + static const char interfaces[]; public: ProgramBuilder(const StandardFeatures &);