]> git.tdb.fi Git - libs/gl.git/blobdiff - source/glsl/optimize.h
Adjust naming of generated variables
[libs/gl.git] / source / glsl / optimize.h
index f6604743810ff1e275198ee554badcd53a75ffa2..e7592c00a29956e7ad4ab09384cf9798b3d1aacf 100644 (file)
@@ -10,8 +10,8 @@ namespace GL {
 namespace SL {
 
 /** Finds functions which are candidates for inlining.  Currently this means
-functions which have no parameters, contain no more than one return statement,
-and are only called once. */
+functions which have no flow control statements, no more than one return
+statement, and are only called once. */
 class InlineableFunctionLocator: private TraversingVisitor
 {
 private:
@@ -49,7 +49,6 @@ private:
 
        FunctionDeclaration *source_func;
        Block staging_block;
-       std::string remap_prefix;
        Pass pass;
        RefPtr<Statement> r_inlined_statement;
        std::set<Node *> dependencies;
@@ -59,7 +58,7 @@ private:
 public:
        InlineContentInjector();
 
-       const std::string &apply(Stage &, FunctionDeclaration &, Block &, const NodeList<Statement>::iterator &, FunctionDeclaration &);
+       const std::string &apply(Stage &, FunctionDeclaration &, Block &, const NodeList<Statement>::iterator &, FunctionCall &);
 
 private:
        virtual void visit(VariableReference &);