Slicing again... simplifying code
-
Hello, I'm still working on slicing scripts, and as functions like projection and lieFlat won't be part of v2, I decided to write a simplier one. My idea was to get a 2d slice of a 3d volume by intersecting it with a volume having a flat top, then only keep the resulting polygons having all vertices with Z corresponding to the flat top Z coordinate. It seems to work fine. My aim is to teach basics of OpenJSCAD to non programmers crafters, so I'm looking for easy code.
The following snapshot shows a tiny jscad allowing to retrieve a cylindrical slice from a volume.
I'm using development web console to have output, that would be great to be able to have output parameters for that, but I understand that is not something critical, it can be handled using the console output.

-
The simple solutions are always the best. Taking a super thin slice is a great idea, and maybe even the best.
The core library will be for core functions, as we expect others (like you) to contribute some really nice high level functionality, such as slicing. If we get the core library rock solid then anything is possible.
Projections on to arbitrary planes is on the wish list, but not there yet.
Thanks for the awesome posts!
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login