Unable to export multiple bodies for optimized cutting

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
User avatar
kreyren
Posts: 17
Joined: Sat Jul 17, 2021 6:53 pm

Unable to export multiple bodies for optimized cutting

Post by kreyren »

I've made a turtlelarium in FreeCAD:
turlelarium_preview.png
turlelarium_preview.png (12.95 KiB) Viewed 1622 times
How can I export it optimized for cutting? e.g.
makeshift_nesting_example.png
makeshift_nesting_example.png (58.21 KiB) Viewed 1622 times
FreeCAD file:

Any relevant info is appreciated! ^-^

FWIW i've tried to export it as flatenedSVG to use Deepnest/SVGNest but i am unable to export invidual pieces as the `Flattened SVG` and DXF files just generate a top-side view:
flatened_SVG_attempt.png
flatened_SVG_attempt.png (85.36 KiB) Viewed 1597 times
Tried to export the shapes using lcinterlocking workbench and then nest them in freecad which generates the flattened parts, but complains about "faces":
Nesting_attempt.png
Nesting_attempt.png (262.07 KiB) Viewed 1555 times
Exporting the flattened SVG in SVGNest causes infinite loading:

Image

---

Expected end-result:
- [DONE] Flattened svg/dxf file
- [HELP_WANTED] Nested image optimized for cutting
Attachments
Turtlerarium.FCStd
(110.38 KiB) Downloaded 33 times
Last edited by kreyren on Tue Jul 20, 2021 12:11 am, edited 6 times in total.
User avatar
PrzemoF
Veteran
Posts: 3520
Joined: Fri Jul 25, 2014 4:52 pm
Contact:

Re: Unable to export multiple bodies for optimized cutting

Post by PrzemoF »

Welcome to the forum!

1. Please read the red banner at the top starting with IMPORTANT...
2. Post all images and files here. Your FreeCAD file will expire in 6 days and the topic will become useless for future users.
3. Ask a proper forum question: what you want to do, what you tried, what was the result, what was the expected result.

Your current post is a borderline case. I thought it's a spam and you almost got banned, but then I found link to the FreeCAD model below the image on an external server.

We're really friendly crowd here - please make some effort to help us help you..
User avatar
kreyren
Posts: 17
Joined: Sat Jul 17, 2021 6:53 pm

Re: Unable to export multiple bodies for optimized cutting

Post by kreyren »

PrzemoF wrote: Sun Jul 18, 2021 6:56 pm Welcome to the forum!

1. Please read the red banner at the top starting with IMPORTANT...
2. Post all images and files here. Your FreeCAD file will expire in 6 days and the topic will become useless for future users.
3. Ask a proper forum question: what you want to do, what you tried, what was the result, what was the expected result.

Your current post is a borderline case. I thought it's a spam and you almost got banned, but then I found link to the FreeCAD model below the image on an external server.

We're really friendly crowd here - please make some effort to help us help you..
Updated the OP to the best of my ability, please check ^-^

Context: Made it to reference my issue, bcs none was answering me on Matrix and IRC on the subject and i didn't expect to get answer here fast enough. So integrated it that way to be able to ask in multiple places u.u
User avatar
PrzemoF
Veteran
Posts: 3520
Joined: Fri Jul 25, 2014 4:52 pm
Contact:

Re: Unable to export multiple bodies for optimized cutting

Post by PrzemoF »

OK, much better now! Thanks!

I'm new to this - check my results. - what's the final result you need? A dxf or svg with all parts close as possible ready for cut? I don't see any errors, but SVGnest have problem with digesting the svg, but (TypeError: p.pathSegList.appendItem is not a function) but that's way outside of FreeCAD, so I'm not sure how to help.

dxf made in FreeCAD
svg produced with inkscape.

Edit: SVGNest can't even convert simple 4 rectangles file in inkscape SVG and plain SVG format.... I guess I just don't understand how to use it.
Attachments
export_shape4.svg
(88.27 KiB) Downloaded 43 times
Turtlerarium.FCStd
(110.38 KiB) Downloaded 33 times
export_shape4.dxf
(64.8 KiB) Downloaded 33 times
User avatar
kreyren
Posts: 17
Joined: Sat Jul 17, 2021 6:53 pm

Re: Unable to export multiple bodies for optimized cutting

Post by kreyren »

PrzemoF wrote: Mon Jul 19, 2021 6:18 pm what's the final result you need? A dxf or svg with all parts close as possible ready for cut?
Yep! Where the main motivation is to make it more economical and reduce waste ideally -> I would like to optimize the sizes that way e.g. if i have 1400x800x400 it should produce around 100mm2 of waste which can be reduced by using 1400x800x500 to get 0mm2 waste
PrzemoF wrote: Mon Jul 19, 2021 6:18 pm dxf made in FreeCAD
svg produced with inkscape.
Your export has the same issue as mine which generates a huge amount of waste (red color):
freecad_flattened_difference.png
freecad_flattened_difference.png (5.39 KiB) Viewed 1501 times
Which according to GIMP the pixel difference is 340461 black to 220005 red -> 340461 / 220005 = 1.5475148 ~= 150.5% -> I have to pay ~50.5% more for the order.

So i need to optimize this for cutting where the ideal (and possible with measurement optimization) scenario is 0% waste
User avatar
PrzemoF
Veteran
Posts: 3520
Joined: Fri Jul 25, 2014 4:52 pm
Contact:

Re: Unable to export multiple bodies for optimized cutting

Post by PrzemoF »

OK, I'd suggest to get in touch with the author of the Laser Cut Interlocking and ask him for help or maybe suggest implementing the nestsvg algorithm.

P.S. I just found out that the workbench is experimental and the author doesn't seem to be active. So you're flying solo: manual placing or the parts, find out what's wrong with nestsvg or find another tool....
User avatar
kreyren
Posts: 17
Joined: Sat Jul 17, 2021 6:53 pm

Re: Unable to export multiple bodies for optimized cutting

Post by kreyren »

PrzemoF wrote: Mon Jul 19, 2021 8:11 pm OK, I'd suggest to get in touch with the author of the Laser Cut Interlocking and ask him for help or maybe suggest implementing the nestsvg algorithm.
FreeCAD has nesting engine (https://forum.freecadweb.org/viewtopic.php?t=23484) i just can't import the shapes in it, bcs it complains about "faces"
User avatar
kreyren
Posts: 17
Joined: Sat Jul 17, 2021 6:53 pm

Re: Unable to export multiple bodies for optimized cutting

Post by kreyren »

So i assume that this is a user-error of me mishandling the objects :/
User avatar
PrzemoF
Veteran
Posts: 3520
Joined: Fri Jul 25, 2014 4:52 pm
Contact:

Re: Unable to export multiple bodies for optimized cutting

Post by PrzemoF »

OK, I didn't know about the built in nesting. Yorik might help.
User avatar
kreyren
Posts: 17
Joined: Sat Jul 17, 2021 6:53 pm

Re: Unable to export multiple bodies for optimized cutting

Post by kreyren »

PrzemoF wrote: Mon Jul 19, 2021 8:45 pm OK, I didn't know about the built in nesting. Yorik might help.
How do i ask yorik to help? I already posted https://forum.freecadweb.org/viewtopic. ... 10#p517823, but none seems to be responding to it
Post Reply