How would you like to use a simple path to create the svg pieces to create a vase like the one below
Using Inkscape and a python program, you can create the pieces needed to make a vase or similar "round" (actually polygon-shaped) 3d objects. Other possibilites would be lampshades, candlesticks, etc.
Interested? Read on...
My wonderful husband, Joe Zakar, has written a Python program that will do pretty much just that. It's called UPC (which originally meant universal polygon generator). Below is all the info that you should need to get started.
Please note that I've written it for those who know how to use Inkscape 1 and Design Space. It generates an svg, which should be usable in other apps, but I have not tested it elsewhere.
upc.pyw -- Help sheet
What is the UPC Program?
You give the program a path that outline silhouette of a simple vase-like shape. It creates the shapes necessary to construct it, using polygons. If your input looks like that pictured above,
...then your ouput would look somthing like this: (the pictures are not equally scaled.)
The output has five paths. These are the score lines, the path around the build piece, the overlay panel (if you want to put patterned paper over the structure after building it this is what you would use. Inset it in Inkscape if you prefer a margin to show around the glue seams.
You would use these "build piece" s to construct your "vase" (or lampshade, or cookie jar, or lamp base... anything the can be constructed with stacked polygons. ) You would duplicate the build piece, with its score lines, for as many times as you have sides in the underlying polygon. If you build on a hexagon, you need six, or if you build on an octagon, you would need 8... etc. If you are using the overlay piece, you duplicat that as well. You'll also get matching polygons to fit the top and bottom. These don't have to be duplicated.
You can duplicate in Design Space or in Inkscape, whichever you prefer.
You might need to do some adjustments in Inkscape, and will likely need to resize in Design Space or other programs. See the known issues, below.
Where to download it?
You can download the program at https://github.com/obzerving/upc
To dowload click on the "CLONE OR DOWNLOAD" button on upper right of the file listings. You will get a zipped folder. Unzip it. The program itself is upc.pyw -- that's the one you'll launch, but before you do....
FOLLOW THE INSTRUCTIONS THERE FOR INSTALLING PYTHON 3 and/or the libraries, if you do not already have it on your computer. You need Python to run Python programs.
Using the upc program.
The program was designed to work in Inkscape 1 (still beta as of this writing). It will not work correctly in earlier Inkscape releases because of the orientation of the canvas.
It will require a pretty specific input file, so please read carefully.
Set up you Inkscape document settings as follows:
Height: 11.5 inches
Width: 11.5 inches
DIsplay Units: Inches
Your input file must contain exactly two paths, one an identical mirror image of the other. They must conain exactly the same number of points and not be grouped. They will NOT be connected at the top and bottom. See the example above.
The simplest way to do that is to create your outline path on one side, duplicate it and flip it horizontally (ctl-d, h). Then simply move it over to the width you prefer. Draw from the top down.
BE SURE TO SAVE YOUR INPUT FILE AS A PLAIN SVG FILE.
Now run the program, using your file as the input. You can change the tab height, the size of the score cuts, whether you want them solid (use 0 for score size), or not there at all, except on the tabs.
Comments and known issues
The output will have the build piece, the score lines, and the overlay piece on top of each other, so it is not obvious that the overlay piece is there also. Keep the scorelines with the build piece. Group if you like. You would attach them in Design Space. If you need to fix funky tabs, it’s easier if you separate the pieces. I suggest adding a fill to everthing just to make it easier to move things around.
On very small segments, the tabs cross over each other. While it would still cut correctly, the little scraps it generates tend to get caught up when cutting, so I recommend fixing any of these in Inkscape. To do that just grab the node tool, select the segment that is criss-crossed over the tab, and join those two nodes together.
NO OUTPUT? Strange dimensions?
If you do not follow all the requirements for the input file , you won't get any output. If that happens, double check that all is as it should be. (The most common problem, in my experience, is forgetting to "save as" as a PLAIN Inkscape file. ) If you get back a report that the finished size is insanely large, you probably left your paths grouped.
If you want, you can switch your output document scale to 72. To do that and keep the size, just select all and cut (ctl-x) all the objects. Then change your scale to 72 , and paste (ctl-c) your objects back in. If you don't use the cut/paste trick, changing the scale will change the size of your objects. When you run the program, it will report a size of the entire output drawing. You can also use that to resize if you need to keep the original dimensions that you drew in the input. If you didn't set up your document properties right, these numbers will be "off".
Note that the fill for the paths wil be the same as that of your input. So if you apply a fill of green to your input paths (they might look odd, because they are not closed paths) , then your output pieces will have a fill. If your input paths have no fill, then the output pieces will also have no fill.
Starting out...something to try.
Try importing a picture of a vase. Use the pen tool to draw a path along the left side (not top or bottom). Duplicate that path (ctl-d). Flip the duplicate horizontally (h). Now use your arrow keys to move that path to be along the right edge of the object in the image. .. Delete the image. Make sure you don't have your paths grouped. Then SAVE AS a PLAIN SVG file. Use this as your input file.
Take a look at your output. See if there are any adjustments (like funky tabs) that you want to fix. Save as plain svg, and upload and use it in Design Space, etc.
Can I use the output directly in Design Space?
Yes, you can actually do that. Just be aware that you will need to resize it and if there are funky tabs, you will need to deal with them there (you can use slice to do that, if you must.)
It is under the GNU/GPL licence.