Hi,
I have a number of vector images I have created. They are all Groups of Paths, some of them up to 50 different paths of different colors.
Now I would like to cut these images up into jigsaw puzzles. I have created some paths that looks like the jigsaw outlines I wish to use.
The first thing I tried was to do Path->Division. It works great for single paths. It will cut the (filled) path up into little pieces according to my cut path. I can, with a single operation, cut a single path up into all the different jigsaw puzzle pieces I need. Unfortunately the path operations will only work on a single path at a time. Since my images can contain 50 different paths I would need to repeat that operation 50 times.
Then a friend suggested me to use Clip. I had never seen it before, and at first it seems fine. I would duplicate my image as many times as pieces I wanted, and clip them one after the other with puzzle piece clip areas. There are two problems with this way. First, the objects are often much larger than the clip path for some reason. Secondly, the svg-file size is much larger now.
What I really would have liked is to perform the Path->Division on all the paths in a group at once. Is there any way to do this? I could also use Path->Intersection, but it seems to have the same "one path at a time"-limitation.
How would you cut a group of paths up into jigsaw puzzle pieces?
Cutting jigsaw puzzle pieces from vector image
Re: Cutting jigsaw puzzle pieces from vector image

Welcome to InkscapeForum!
Actually for Path Intersection, you should be able to use as many paths as you want. The path on top will define the border, so as long as the jigsaw piece is on top, it should work. But you'll have to do it as many times as you have pieces in the puzzle.
Don't those cutter machines cut out jigsaw puzzles? I'm just thinking that you would need to use some automated software or hardware to cut it all at once. (like a jigsaw

I'm not sure though. Maybe someone else will be more informative, and I'll be interested to learn more about it

Basics - Help menu > Tutorials
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design
Re: Cutting jigsaw puzzle pieces from vector image
The result of intersecting multiple paths with the one stacked on top (in one go) is not the same as when dividing each path individually with a 'cutting' path stacked on top. Secondly, 'Path > Intersection' works on areas and always creates closed paths (not useful if open paths are among the objects to cut).brynn wrote:Actually for Path Intersection, you should be able to use as many paths as you want.
Unfortunately this is not possible - Inkscape does not have a 'razor' tool which would perform such an action automatically. For now, path operations like 'Path > Divide' or 'Path > Cut' are limited to two paths. The feature request for a razor tool has been filed a long time ago, but not been implemented yet.Offler wrote:What I really would have liked is to perform the Path->Division on all the paths in a group at once.
A clip does not actually cut paths - it limits the visible area within which the clipped object is displayed. The path itself stays unchanged (with regard to its geometry) and the clip can be released again any time (or it can be edited without even releasing the clip).Offler wrote:I would duplicate my image as many times as pieces I wanted, and clip them one after the other with puzzle piece clip areas. (…) There are two problems with this way. First, the objects are often much larger than the clip path for some reason. Secondly, the svg-file size is much larger now.
Not sure what "the objects are often much larger than the clip path for some reason" is about - there is a known (and annoying) selection glitch with clipped objects (still present in latest stable 0.48.2, but fixed for up-coming 0.48.3), where you cannot 'click through' the invisible (clipped-away) area of a clipped object to select objects stacked below (bug #365458).
The actual file size probably depends on how large the original paths are compared to the clipped area (this would explain why you seem to expect a lower file size).
Last edited by ~suv on Wed Oct 12, 2011 2:46 am, edited 1 time in total.
Re: Cutting jigsaw puzzle pieces from vector image
you might be way ahead to raster the graphic and use gimp to make your puzzle
Re: Cutting jigsaw puzzle pieces from vector image
Offler wrote:I have a number of vector images I have created. They are all Groups of Paths, some of them up to 50 different paths of different colors.
Now I would like to cut these images up into jigsaw puzzles. I have created some paths that looks like the jigsaw outlines I wish to use.
What I'd probably do:
- turn the vector image into a custom pattern (menu 'Object > Pattern > Objects to Pattern')
results in a rectangle which has a pattern fill applied - create one large path combining all lines needed to divide the rectangle into the jigsaw pieces
- divide the rectangle from step 1 with the path from step 2 (using 'Path > Division')
Attaching a quick test - the individual steps are on (hidden) layers (starting with the lowest one). The one on the top is just for fun ("unclumped" clones of the original pieces (see 'Align & Distribute)).
- Attachments
-
- jigsaw-with-custom-pattern-fill-2.png (146.46 KiB) Viewed 6300 times
-
- jigsaw-with-custom-pattern-fill-2.svgz
- (44.51 KiB) Downloaded 432 times
Re: Cutting jigsaw puzzle pieces from vector image
Drawback of the pattern fill method: if you depend on a special output format (e.g. DXF, HPGL, PLT) for a cutting machine or plotter, the pattern fills will not export AFAIK. And there is no way in Inkscape to 'flatten' such pattern fills i.e. convert them into paths.
Re: Cutting jigsaw puzzle pieces from vector image
Thank you very much everyone for all the quite long explanations and ideas.
Now I know for sure that the path operations are limited to two paths. That would have been the preferred way for me, but I guess I will have to dive into the source code (not so realistic) or simply wait.
I also got some good ideas for going through bitmap, either in inkscape or maybe gimp. Before I had the idea that I wanted vector format to use in my application, but I am starting to doubt how useful that is compared to the extra work to get it done.
Right now I'm thinking that I will either use clip or do something after converting the group of paths to bitmap.
Thank you all very much!
Now I know for sure that the path operations are limited to two paths. That would have been the preferred way for me, but I guess I will have to dive into the source code (not so realistic) or simply wait.
I also got some good ideas for going through bitmap, either in inkscape or maybe gimp. Before I had the idea that I wanted vector format to use in my application, but I am starting to doubt how useful that is compared to the extra work to get it done.
Right now I'm thinking that I will either use clip or do something after converting the group of paths to bitmap.
Thank you all very much!
Re: Cutting jigsaw puzzle pieces from vector image
Offler wrote:Now I know for sure that the path operations are limited to two paths.
Path Intersection can be done on 2 or more paths at once. But as ~suv pointed out, it won't work on open paths.
From the Guide
"• Intersection (Ctrl+*): Intersection of two or more paths. The new path encloses the common area of the original paths."
I wonder if it might be helpful to include this as a footnote in the Guide, that path intersection only works on closed paths?
Basics - Help menu > Tutorials
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design
Re: Cutting jigsaw puzzle pieces from vector image
brynn wrote:Offler wrote:Now I know for sure that the path operations are limited to two paths.
Path Intersection can be done on 2 or more paths at once. But as ~suv pointed out, it won't work on open paths.
From the Guide
"• Intersection (Ctrl+*): Intersection of two or more paths. The new path encloses the common area of the original paths."
I wonder if it might be helpful to include this as a footnote in the Guide, that path intersection only works on closed paths?
I don't really understand how 'Path > Intersection' would be relevant for the issue at hand at all: the result of this operation is a single path (enclosing "the common area of the original paths") - the original question here was how to cut multiple paths in one go (the result being still multiple paths, cut be the same one cutting path on top).
brynn wrote: But as ~suv pointed out, it won't work on open paths.
That's not what I said ;)
It does work on open paths, but one has to be aware of that the path operations (except Division and Cut) work on areas not path outlines. 'Path > Intersection' works with unclosed paths as long as they circumscribe an area (i.e. no straight lines) and creates a closed area (intersection ≠ Division) if successful.
Re: Cutting jigsaw puzzle pieces from vector image
~suv wrote:brynn wrote:Offler wrote:Now I know for sure that the path operations are limited to two paths.
Path Intersection can be done on 2 or more paths at once. But as ~suv pointed out, it won't work on open paths.
From the Guide
"• Intersection (Ctrl+*): Intersection of two or more paths. The new path encloses the common area of the original paths."
I wonder if it might be helpful to include this as a footnote in the Guide, that path intersection only works on closed paths?
I don't really understand how 'Path > Intersection' would be relevant for the issue at hand at all: the result of this operation is a single path (enclosing "the common area of the original paths") - the original question here was how to cut multiple paths in one go (the result being still multiple paths, cut be the same one cutting path on top).brynn wrote: But as ~suv pointed out, it won't work on open paths.
That's not what I said
It does work on open paths, but one has to be aware of that the path operations (except Division and Cut) work on areas not path outlines. 'Path > Intersection' works with unclosed paths as long as they circumscribe an area (i.e. no straight lines) and creates a closed area (intersection ≠ Division) if successful.
I gave it a shot, suggesting Intersection, but without a screenshot, I really don't know what the image is composed of. My thought was to do the intersection operation once for each puzzle piece, because I couldn't think of a way to do it all at once. If it turns out that it won't work, I'm sorry that my suggestion won't work. But I think I made it clear that I wasn't sure how to do it.
All I wanted to do (in my last reply) was point out that Intersection works on 2 or more paths, as per the Guide.
It does work on open paths, but one has to be aware of that the path operations (except Division and Cut) work on areas not path outlines.
This is not made clear in the Guide, and I was wondering if it might be helpful to include a footnote to that effect? I doubt if I'm the only user to be confounded by the path operations, despite consulting the Guide.
Basics - Help menu > Tutorials
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design