Incongruent skewing / Foreshortening of an existing object

Post questions on how to use or achieve an effect in Inkscape.
wfaulk
Posts: 2
Joined: Fri Jul 09, 2010 7:41 am

Incongruent skewing / Foreshortening of an existing object

Postby wfaulk » Fri Jul 09, 2010 7:49 am

I have an existing SVG object that I want to transform such that the bottom becomes smaller than the top. If the object were a square, I would want the result to look like a top-heavy trapezoid.

It seemed to me that this would be a trivial thing to do, but I'll be darned if I can figure it out.

The object is not terribly complex, and can be easily reduced to a group of paths, but it cannot be represented as a single path.

User avatar
prkos
Posts: 1625
Joined: Tue Nov 06, 2007 8:45 am
Location: Croatia

Re: Incongruent skewing / Foreshortening of an existing object

Postby prkos » Fri Jul 09, 2010 9:40 am

For square you just convert it to a path and use Node tool to move the nodes (hold Ctrl to keep them horizontal.)

For complex objects look into Live Path effects, Envelope, Bend path, maybe some others... Read about them in the Inkscape guide.
just hand over the chocolate and nobody gets hurt

Inkscape Manual on Floss
Inkscape FAQ
very comprehensive Inkscape guide
Inkscape 0.48 Illustrator's Cookbook - 109 recipes to learn and explore Inkscape - with SVG examples to download

vwanweb
Posts: 169
Joined: Sun Jun 06, 2010 1:48 pm

Re: Incongruent skewing / Foreshortening of an existing object

Postby vwanweb » Fri Jul 09, 2010 1:48 pm

I've attached an inkscape file showing the steps I recommend for creating the effect you are looking for. It seems cumbersome at first pass, but allowing you to control the perspective per object is something that is a bit of a jewel..


Having noted this I agree an easier to use envelope deformation would be a nice feature in inkscape. When working with envelope perspectives for text I use Open Draw's 'Fontwork' gallery. And then 'export' the Open Draw workup as .pdf or .svg.. to get it ready for import (.pdf) or opening (.svg) in Inkscape. Alot faster and Open Draw has a dedicated menu with different (15+) envelope presets.

Draw Freely!

EnvelopeInkscape.svg
Envelope In Inkscape 0.47
(75.95 KiB) Downloaded 359 times

wfaulk
Posts: 2
Joined: Fri Jul 09, 2010 7:41 am

Re: Incongruent skewing / Foreshortening of an existing object

Postby wfaulk » Sat Jul 10, 2010 12:47 am

vwanweb wrote:I've attached an inkscape file showing the steps I recommend for creating the effect you are looking for.

Thanks!

There's a problem with your method, though. Not all of the sub-objects in my object are at the edge, so the one reference path isn't enough.

Actually, taking a second look, there doesn't seem to be a need to ungroup the object. Applying an envelope deformation to the whole thing seems to work fine.

Except: it relies on the idea that I'm precise, which is, uh, not true. (That's what the computer is for!) I end up with weird bulges.

OO.o Draw's Fontwork Gallery isn't exactly what I'm looking for, as my object is not text. However, its "Distort" is. I can select my whole object, apply Distort, and move the corners in. This is exactly what I was trying to do with Inkscape, and is as easy in Draw as I was expecting it to be. Thanks for the pointer!

User avatar
Xav
Posts: 1209
Joined: Fri May 08, 2009 1:18 am
Location: UK
Contact:

Re: Incongruent skewing / Foreshortening of an existing object

Postby Xav » Sat Jul 10, 2010 2:15 am

Another hacky workaround approach is the one I used for the abacus in this comic strip: I exported my "flat" abacus as a PNG, opened it in The GIMP, and altered it in there to give the sort of perspective I was looking for. Then I saved that image, dragged it back into the Inkscape window, and locked it in the background as a guide to help me manually adjust the nodes and shapes of the original image. Once I was happy with the result I unlocked the PNG and removed it from the image, leaving me with just the distorted vector version.

Not a fast, good or pretty approach, but it worked.
Co-creator of The Greys and Monsters, Inked - Inkscape drawn webcomics
Web SiteFacebookTwitter

vwanweb
Posts: 169
Joined: Sun Jun 06, 2010 1:48 pm

Re: Incongruent skewing / Foreshortening of an existing object

Postby vwanweb » Sat Jul 10, 2010 5:38 am

wfaulk wrote:
vwanweb wrote:I've attached an inkscape file showing the steps I recommend for creating the effect you are looking for.


Actually, taking a second look, there doesn't seem to be a need to ungroup the object. Applying an envelope deformation to the whole thing seems to work fine.

Except: it relies on the idea that I'm precise, which is, uh, not true. (That's what the computer is for!) I end up with weird bulges.



Setting the Envelope per object will eliminate the WEIRD bulges you are refencing.

~suv
Posts: 2272
Joined: Sun May 10, 2009 2:07 am

Re: Incongruent skewing / Foreshortening of an existing object

Postby ~suv » Sat Jul 10, 2010 10:59 am

vwanweb wrote:Setting the Envelope per object will eliminate the WEIRD bulges you are refencing

"bulges" can be avoided by
  1. apply LPE directly on group
  2. deactivate top&bottom bend paths
  3. node-edit right bend path (select both nodes and scale with '.' (keyboard shortcut))

LPE-Envelope-on-group-1.png
LPE-Envelope-on-group-1.png (40.19 KiB) Viewed 6111 times

Note: Envelope Deformation is not a 'Perspective' deformation (Extensions > Modify Path > Perspective).
Attachments
LPE-Envelope-on-group-1.svg
(75.48 KiB) Downloaded 213 times

~suv
Posts: 2272
Joined: Sun May 10, 2009 2:07 am

Re: Incongruent skewing / Foreshortening of an existing object

Postby ~suv » Sat Jul 10, 2010 11:07 am

You can even use the text object itself (allows to edit its content as text while the path effect gets live-updated) by stacking path effects (Pattern-Along-Path + Envelope-Deformation):

Re: Expanding text by J.B.C.Engelen

erroneus
Posts: 31
Joined: Fri Jul 03, 2009 6:25 am

Re: Incongruent skewing / Foreshortening of an existing object

Postby erroneus » Sun Jul 11, 2010 5:44 pm

I am interested in this topic as I have run into the very same situation where I wanted to create the shadow of a character I drew. (see attached result)
kirin.svg
Kirin is Japanese for Giraffe
(28.96 KiB) Downloaded 231 times


In this case, I used some envelope extension to accomplish it where I drew an oddly shaped four-sided polygon and selected the two things and using "envelope" it deformed the object into the shape I wanted. The problem was that there was a LOT of trial and error and in the end, I don't really remember how I arrived at the result I wanted. I seem to recall it had something to do with the order of the the points I drew in the envelope polygon because my first few attempts ended up rotating the figure in strange ways.

What I would like to be able to do is select my grouped object and then play with the bounding box's dimensions as I think that would be a more natural approach to what I think would be a common situation.

(Also, what do y'all think of my giraffe?)

~suv
Posts: 2272
Joined: Sun May 10, 2009 2:07 am

Re: Incongruent skewing / Foreshortening of an existing object

Postby ~suv » Sun Jul 11, 2010 6:31 pm

...
Attachments
erroneus-kirin-variants.png
erroneus-kirin-variants.png (157.11 KiB) Viewed 6082 times

erroneus
Posts: 31
Joined: Fri Jul 03, 2009 6:25 am

Re: Incongruent skewing / Foreshortening of an existing object

Postby erroneus » Sun Jul 11, 2010 6:55 pm

Wow! You can say SO MUCH MORE in pictures than you can say in words. Thanks to ~suv for that fine example! With that, I was able to understand exactly what I was trying to do and what I was doing wrong. Most importantly, I was actually closing the path I was defining which was completely unnecessary. The numbered points also make the process extremely clear. This is a useful lesson I will remember into the future as it makes lots more sense now than ever before. (though it was neglected to say what was thought of my giraffe picture... oh well, fishing for compliments never works well for me... I usually end up with something closer to the truth.)

~suv
Posts: 2272
Joined: Sun May 10, 2009 2:07 am

Re: Incongruent skewing / Foreshortening of an existing obje

Postby ~suv » Sun Jul 11, 2010 7:25 pm

erroneus wrote:though it was neglected to say what was thought of my giraffe picture...

Image
"If only I'd look half as cute as Kirin... Sigh."


** Image retreived from lancien.cowblog.fr


Return to “Help with using Inkscape”