add method for output path

This commit is contained in:
Ben Fry
2015-05-15 16:03:00 -04:00
parent c37e9dc81e
commit 6ae3a56d88

View File

@@ -159,6 +159,7 @@ public class PdePreprocessor {
protected String sketchWidth;
protected String sketchHeight;
protected String sketchRenderer;
protected String sketchOutputPath;
/**
* Regular expression for parsing the size() method. This should match
@@ -208,6 +209,7 @@ public class PdePreprocessor {
sketchWidth = info[1];
sketchHeight = info[2];
sketchRenderer = info[3];
sketchOutputPath = info[4];
}
return info;
}
@@ -955,6 +957,9 @@ public class PdePreprocessor {
out.println(indent + "public String sketchRenderer() { return " + sketchRenderer + "; }");
//}
}
if (sketchOutputPath != null && !hasMethod("sketchOutputPath")) {
out.println(indent + "public String sketchOutputPath() { return " + sketchOutputPath + "; }");
}
if (!hasMethod("main")) {
out.println(indent + "static public void main(String[] passedArgs) {");