Dead easy, at least for a Linux user.
If you run OpenSCAD from the command line - which I don't bother to do - you
would just chain OpenSCAD > YourProgram > OpenSCAD and be done.
What I do is open MyProgram in its IDE, run it to create a .stl file,
transfer focus from my IDE to OpenSCAD, press F4 (to refresh OpenSCAD) and
then F5 or F6, as required.
Done.
BTW: MyProgram is written in such a way that it converts a .STL file into
the format OpenSCAD needs to run its own polyhedron(Points,Faces) command.
That way, I can have the benefits of both.
The advantage - to me- is that I get full control over what OpenSCAD does
internally, without the need to study its internals. That includes ways and
means to eliminate CGAL assertion errors, and it produces ways to
dramatically speed up rendering.
But - because of the way the .STL file format is designed, this approach
limits accuracy of output to three or four decimal places, instead of the
six possible with 32 bit floats and the 19 decimals possible when using the
full capabilities of existing 64 bit hardware.
What I would like to see is an polymorphic extension to polyhedron(), so
that it accepts a suitably ordered list of points.
Because: Once the list of points is suitably ordered, the list of faces may
be generated internally. Once you don't need to bother to create the list of
faces, the need to do boolean operations decreases dramatically, and
rendering time for complex shapes drops from hours to seconds.
To generate a suitably ordered list of points can readily be done with a for
loop.
wolf
--
View this message in context: http://forum.openscad.org/how-easy-to-make-off-export-a-function-call-tp21595p21602.html
Sent from the OpenSCAD mailing list archive at Nabble.com.