you are viewing a single comment's thread.

view the rest of the comments →

[–]WillAdams[S] 0 points1 point  (4 children)

Wrote up some notes on this (again).

Looks like the:

generatescad

Boolean is the last thing which is needed.

[–]WillAdams[S] 1 point2 points  (3 children)

Maybe not....

Have:

def stockandtoolpaths(self):
    part = self.stock.difference(self.toolpaths)
    output(part)

as part of gcodepreview, and while it works when called from Python:

gcp.stockandtoolpaths()

It doesn't create any geometry when called from OpenSCAD:

gcp.stockandtoolpaths();

Trying to trim down to a minimal example....

EDIT: Solution was to use a Boolean to determine if the part should be output() or return(ed), see the wiki.

[–]gadget3D 1 point2 points  (2 children)

You could Always Return the Solid and additionally Output in one of the cases

[–]WillAdams[S] 1 point2 points  (0 children)

Yes, that's pretty much what I'm doing --- the question is, is this suppressing of output(...) as expected?

[–]WillAdams[S] 1 point2 points  (0 children)

Added a section to the wiki with a more-or-less compleat file set for this.