diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/openscad.cc | 6 | ||||
| -rw-r--r-- | src/rendersettings.cc | 2 | 
2 files changed, 7 insertions, 1 deletions
| diff --git a/src/openscad.cc b/src/openscad.cc index 0fa9f92..5c21fa9 100644 --- a/src/openscad.cc +++ b/src/openscad.cc @@ -113,6 +113,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%[ --csglimit=num ] \\\n"           "%2%[ --enable=<feature> ] \\\n"           "%2%filename\n",   				 progname % (const char *)tabstr); @@ -581,6 +582,7 @@ int main(int argc, char **argv)  		("info", "print information about the building process")  		("render", "if exporting a png image, do a full CGAL render")  		("preview", po::value<string>(), "if exporting a png image, do an OpenCSG(default) or ThrownTogether preview") +		("csglimit", po::value<unsigned int>(), "if exporting a png image, stop rendering at the given number of CSG elements")  		("camera", po::value<string>(), "parameters for camera when exporting png")  	        ("imgsize", po::value<string>(), "=width,height for exporting png")  		("projection", po::value<string>(), "(o)rtho or (p)erspective when exporting png") @@ -622,6 +624,10 @@ int main(int argc, char **argv)  		if (vm["preview"].as<string>() == "throwntogether")  			renderer = Render::THROWNTOGETHER; +	if (vm.count("csglimit")) { +		RenderSettings::inst()->openCSGTermLimit = vm["csglimit"].as<unsigned int>(); +	} +  	if (vm.count("o")) {  		// FIXME: Allow for multiple output files?  		if (output_file) help(argv[0]); diff --git a/src/rendersettings.cc b/src/rendersettings.cc index e9c2f63..ba68dc5 100644 --- a/src/rendersettings.cc +++ b/src/rendersettings.cc @@ -12,7 +12,7 @@ RenderSettings *RenderSettings::inst(bool erase)  RenderSettings::RenderSettings()  { -	openCSGTermLimit = 2000; +	openCSGTermLimit = 100000;  	far_gl_clip_limit = 100000.0;  	img_width = 512;  	img_height = 512; | 
