diff options
Diffstat (limited to 'src/openscad.cc')
-rw-r--r-- | src/openscad.cc | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/openscad.cc b/src/openscad.cc index ab84235..16a6e89 100644 --- a/src/openscad.cc +++ b/src/openscad.cc @@ -33,6 +33,7 @@ #include "builtin.h" #include "printutils.h" #include "handle_dep.h" +#include "feature.h" #include "parsersettings.h" #include "rendersettings.h" #include "PlatformUtils.h" @@ -111,6 +112,7 @@ static void help(const char *progname) "%2% --camera=eyex,y,z,centerx,y,z ] \\\n" "%2%[ --imgsize=width,height ] [ --projection=(o)rtho|(p)ersp] \\\n" "%2%[ --render | --preview[=throwntogether] ] \\\n" + "%2%[ --enable=<feature> \\\n" "%2%filename\n", progname % (const char *)tabstr); exit(1); @@ -587,7 +589,8 @@ int main(int argc, char **argv) ("x,x", po::value<string>(), "dxf-file") ("d,d", po::value<string>(), "deps-file") ("m,m", po::value<string>(), "makefile") - ("D,D", po::value<vector<string> >(), "var=val"); + ("D,D", po::value<vector<string> >(), "var=val") + ("enable", po::value<vector<string> >(), "enable experimental features"); po::options_description hidden("Hidden options"); hidden.add_options() @@ -651,6 +654,11 @@ int main(int argc, char **argv) commandline_commands += ";\n"; } } + if (vm.count("enable")) { + BOOST_FOREACH(const string &feature, vm["enable"].as<vector<string> >()) { + Feature::enable_feature(feature); + } + } vector<string> inputFiles; if (vm.count("input-file")) { inputFiles = vm["input-file"].as<vector<string> >(); |