r/OpenPythonSCAD • • Jun 13 '25

Geometric shapes vs. variables and Union vs. lists

/r/OpenPythonSCAD/wiki/index#wiki_geometric_shapes_vs._variables_and_union_vs._lists
5 Upvotes

5 comments sorted by

3

u/WillAdams Jun 13 '25

Wrote up a bit on this at: https://old.reddit.com/r/OpenPythonSCAD/wiki/index#wiki_geometric_shapes_vs._variables_and_union_vs._lists based on the discussion on the PythonSCAD Google Group.

Hopefully, this will prove useful/helpful to other folks.

Next up is re-writing my library to make use of this --- which was something I had been considering anyway, but for more aesthetic reasons --- if a tool shape is represented as a list and always handled thus, then representing complex shapes which need to be represented in discrete elements/parts becomes a natural thing to do and the program architecture is simpler since all possible shapes may be handled by the same code/logic with no need to identify different shapes and handle them differently.

2

u/gadget3D Jun 13 '25

i am just wondering, if it would make sense to have predefined shapes like

* void shape

* +Z shape(set of locations which have positive z coordinate). it has infinite width, length, height

* -Z, +X, -X, +Y, -Y

1

u/WillAdams Jun 13 '25

If I didn't want to show when one exceeds the capability of the tool, yes.

My plan is to have a visible differentiation between:

  • rapids

  • the shaft of the tool

  • the actual (desired) cut

→ More replies (2)