Nesting or organisation of shapes

I have a 900x600 laser, and a file with about 230 individual parts that will need many different sheets to complete.

When I import my dxf file, I have a heck of a job going through and organising which parts fit and selecting/deselecting which to cut.

So, I have to do all of that outside of Lightburn and then bring the nested file in to cut.

One thing I like about Lightburn is that I rarely have to go out to a third-party app to get things done, so a built-in nesting tool would be a real boon.

There’s a few open-source ones to look at that could become the basis for a Lightburn nesting tool:

https://deepnest.io is the best I have found to date.

1 Like

The problem with open source is that if you use them in your software, you have to make your software open source as well. OZ will need to write his own nesting software if he wants to add the feature to LightBurn.

That is not always true, it depends on the license. I checked deepnest and it’s license allows for commercial use in closed source projects. That said, many devs don’t want to deal with the legal aspects of using open source and will just roll their own to avoid it.

Nobody suggested using open source software, and you’re wrong about having to make yours open source.

Not a programmer or patent lawyer, I take it?

The suggestion was to get ideas of how nesting algorithms work, not to clip code

I emailed Oz a while back to see if he had considered investigating the possibility of incorporating Deepnest code into LB. He said he had looked into the coding/design and that it wasn’t a good candidate for being part of LB.

SVGNest has a permissive license, though I’m not sure if DeepNest does as well. Both are primarily written in JavaScript, and not nearly as modular as they could be. Implementing nesting is on my wishlist, but it’ll take a chunk of time to do.

1 Like

Thanks. It would be a useful tool.

1 Like

After doing some more work with Deepnest, I’ve come to the realisation it’s a complete pile of poo. It does a great job of nesting, but it doesn’t handle dxf files properly - my 380mm object came in at 1077mm.

After playing around some, I managed to get it in at 400mm-ish. Not close enough.

What kind of numb nut produces something that changes the scale so badly?

Apparently the author hasn’t been seen since he produced it - there’s an increasing bug list and he hasn’t addressed a single one, so Deepnest is off the list.

I’ll give SVGnest a look, but never work in SVG files and would have to do multiple conversions… grrrr.

DXF files do not store the unit of measure used, so that could be the issue. If you saved it in cm but load it as inches, for example, the scale would be 2.54x larger. I’m amazed that DXFs (being a CAD / engineering format) have this issue.

I’ve dug through the code a bunch and it’s a bit of a mess, and almost entirely written in JavaScript, so it would need a full port. It’ll happen, but it’ll take time.

Yeah, I’m not new at this… 40+ years of systems engineering means I don’t make basic mistakes like mix up mm and inches. His app is flawed.

I never use inches, for anything. It would take a conscious and determined effort. I’m a product of binary, decimal/metric and hex. You can keep yer weird base-12 Latin nonsense.:wink: Heck, I’m for going full metric calendar!

I’ve tried putting in various numbers to the SVG ratio to try and work out where the calculation is. I suspect he’s converting from metric to inches and back multiple times and building up such a set of rounding errors that my 6mm becomes 6.92mm in just a few moves. I’ve seen that kind of thing in CNC apps and slicers, too.

And thanks for the commitment - nesting is such a time-consuming task and if you can knock it off, will truly make this (more of ) a standout product.

And… while we’re on the subject of shape management, I would like to see some method of chaining jobs.

For example: I have 7x sheets worth of shapes to cut. How I handle it at the moment is to manually nest a full sheet, group it and assign it to a non-cutting colour. Repeat for the other six sheets. Then I pick a sheet, assign it to a material, flip the ‘cut’ tag, move it to the centre and run. Repeat for the other six.

A way of stacking those seven groups and running through them sequentially would be fab.

Of course, I may just be looking at it wrong (it’s been known to happen) and my workflow is whack.

I had a similar problem with things not scaling correctly. I try to convert to .svg first since it seems to work best. It is funny how you can run the same file multiple times and get different results each time. Sometimes barely different in terms of efficiency but other times unacceptably different. Nature of the beast I guess but you have to hope you don’t get a bad “run” if you only run it once.

You know the same guy wrote svgnest and then Deepnest, right? Each has its flaws but at least svgnest is free. Since he isn’t making money on it, I give him props for maintaining a website that can sometimes be helpful.

Add your vote here to get updates when development starts / progresses:

The plan for this is to have multiple pages within a LightBurn file, all sharing the same cut settings.

1 Like

No, the developer of deepnest took svgnest and added stuff, like dxf import.

Svgnest works fine, but I was trying to avoid another conversion.

And if he maintained it, it would probably be fixed. He has 58 outstanding issues, some of which date back to when he released the app. He’s not replied to a single one.