SVGnest icon indicating copy to clipboard operation
SVGnest copied to clipboard

Locked pieces

Open schrade opened this issue 9 years ago • 15 comments

There are times in a job where there are pieces that are required to be in certain locations - due to grain or wood imperfections, etc. After these pieces are located in their manually approved locations it would be desirable to nest remaining pieces. Sometimes it is as simple as the 'primary' pieces are paying for the job and need to be in the best parts of the material, and then the remainder of the material can be used to nest pieces of 'secondary' value.

Note: this is NOT a duplicate request to the 'piece orientation' request - but obviously I'd mark the primary pieces by location and orientation.

Implementation thought: When the initial nesting container is selected and the process triggered, anything already within the container boundaries is treated as locked both positionally and with regard to orientation. Nesting resumes from there?

schrade avatar Feb 20 '16 22:02 schrade

so I think this is do-able, but will require a bit of refactoring.

I'll add it to the todo list

Jack000 avatar Feb 22 '16 12:02 Jack000

Good to hear that this is doable. Refactoring code, the most enjoyable of tasks!

Thanks for the reply and I look forward to testing the fruits of your labor.

Edit: One other thought - I don't know how most people use this software. But if people are using SVG that contains their initial human attempt at nesting, it might make sense to have a setting that indicates they desire this new feature to be in use. "Treat items within the nesting container as locked" checkbox or something similar. Just trying to help.

schrade avatar Feb 27 '16 14:02 schrade

+1. This is a great feature On Feb 27, 2016 6:14 AM, "schrade" [email protected] wrote:

Good to hear that this is doable. Refactoring code, the most enjoyable of tasks!

Thanks for the reply and I look forward to testing the fruits of your labor.

— Reply to this email directly or view it on GitHub https://github.com/Jack000/SVGnest/issues/19#issuecomment-189646037.

eric-schleicher avatar Feb 27 '16 16:02 eric-schleicher

Another use case for this feature came to mind yesterday when I was trying to pick up where I left off on a previous sheet. Sometimes I have a project that only takes a partial sheet to complete. So a person using SVGNest would get a maximum amount of use out of that partial sheet.

A week later, I want to use more of the sheet. I've got my previously optimized work, and I want to nest the new stuff - but I can't pick up where I left off. With this feature in place, I can resume the use of the partial sheet.

So anyway, thanks for your efforts here. I really am looking forward to seeing this feature work when you get the time to implement it.

schrade avatar Feb 27 '16 17:02 schrade

@schrade @Jack000 "Treat items within the nesting container as locked" checkbox or something similar.

This is good way to solve this problem.

lancer99 avatar Nov 02 '16 08:11 lancer99

Dear @Jack000 , first of all, congratulations for the project. I am trying to use it. I think an important feature is to give some orientation for the container and for the piece. I don't like to lock the piece in a specific place but I want to keep it in a given direction, for instance. This is a special use on the fabric where we need to cut clothes following the fabric fiber. I understand that to do this, the container and the pieces may have orientation, for instance, North, South, and so on. Do you think it is possible to to that?

aurimrv avatar Nov 29 '18 16:11 aurimrv

@aurimrv you might try Deepnest and set rotation to 0. Havent tried that before but worth a try

dorkmo avatar Nov 29 '18 16:11 dorkmo

Dear @dorkmo, thank you. I will try it. Cheers

aurimrv avatar Nov 30 '18 10:11 aurimrv

Dear @dorkmo, do you know where I set rotation to 0 in Deepnest?

aurimrv avatar Nov 30 '18 10:11 aurimrv

I think I found it, but it seems to apply rotation globally. In my case, it is necessary that this rotation should be applied by piece.

aurimrv avatar Nov 30 '18 10:11 aurimrv

hmm, Im not sure i understand. For each piece's file, are they aligned in the desired orienation? So north is up in each file?

dorkmo avatar Nov 30 '18 13:11 dorkmo

Dear @dorkmo , I attached a figure to try to explain. Suppose the container has an orientation, for instance, north. Then, for each piece I need to arrange inside the container, I would like to set its orientation too. In this way, for some pieces, the algorithm can only move it in a specific direction.

piece-rotation

This is mainly useful to cut clothes. For instance, when you want to cut a particular piece of clothing according to the direction of the pattern of the fabric.

aurimrv avatar Dec 03 '18 16:12 aurimrv

These pieces with arrows can be moved only respecting the direction of the container or on its inverse direction. On the other hand, the other pieces can be freely rotated.

aurimrv avatar Dec 03 '18 16:12 aurimrv

as a work around i wonder if you could somehow manually connect the difference pieces with a small line to make them one big piece

dorkmo avatar Dec 08 '18 18:12 dorkmo

I need the same functionality desperately. I cannot use this project at the moment because I cannot define orientation/grain per piece. I sent an email to Jack asking him what modifications need to be done in order to make this possible in the code and I'm waiting for his answer.

cptX avatar Jan 16 '19 11:01 cptX