Thursday, April 05, 2007

Inkscape Screencast 8 - Perspective

My 8th Inkscape screencast is now posted. This one involves the perspective effect in Inkscape. I tried to just illustrate the basics of using it. With a little imagination you can achieve some neat things with it. I've been using it for a few of my entries in the xmms2 logo contest.

I had a bit of trouble using the effect on my linux machine. It would work fine, but always popped up a warning dialog. Not great stuff for a screencast. A developer named acspike helped me out by creating a fix to suppress the messages. Good stuff!

The intro as always, was fun to make, and while speeding it up achieved what I wanted, I had a little trouble joining it up to the main screencast portion because they differed in frame rates. However a little playing around with avidemux let me match the frame rates and all was well in the end.

Hope you like it and find it useful.

[Update: Thanks to Joe H in the comments. He pointed out, quite correctly, that you don't have to combine paths into one before applying the perspective effect. You can just group them. This lets you 'perspectivize' paths with differing fill, stroke and colour properties without losing those properties. - Thanks Joe! and check out the sample book and cup image he posted in the comments - awesome!]

Click right here to see the other screencasts I've posted.


heathenx said...

NICE! I watch your tutorials because I want to learn new things, obviously...but your intros are absolutely entertaining.

GREAT WORK, Richard!

Will said...

Great as usual. Intro was fun. Handy tip.

I had a couple of problems with Inkscape. I'm on Feisty Beta & Inkscape 0.45, built Apr 4 2007 (pretty current give today is Apr 4 2007)

I had to add the package python-numpy to get the perspective effect to work. I was getting an error ... File "/usr/share/inkscape/extensions/", line 23, in module from numpy import * ImportError: No module named numpy... This is now fixed with numpy.

Now I get a complaint ...Format autodetect failed inkscape... and I acknowledge the error and perspective works.

Richard you said you got some help with this and I found part of that discussion on the Inkscape forums but the resolution is still elusive to me and google. Care to share?

RichardQuerin said...

@heathenx - thanks for the compliment!

@will - you're getting the same warning dialog as I was by the sounds of it. acspike pointed me to a revised file that fixed the problem. I'm not sure if it's been added to the available patches yet. Below is the link he sent me. Just go there, download it and replace the existing file (back up the original one first of course) and restart Inkscape. Good luck and let me know if it worked for you. Glad you found the intro fun - it served its purpose then. :)

link to revised file location

Will said...

Thanks, that patched above, works great. No more complaints from inkscape.

earl said...

The OS X release of Inkscape also has problems with Perspective. It's asking for an additional extension file.

When I get a chance I'll see if I can get it working.

Richard, enjoyed the screencast!

Jos Hirth said...

It doesn't need to be a single path. Groups (of paths) also work.

Eg I did the book's cover in one go:

However, like interpolate it doesn't handle transformations very well. Hopefully it will be replaced with something more interactive/intuitive in the future.

RichardQuerin said...


Thanks for the comment. You are correct, groups of paths work, not necessarily just combined paths. I wonder if that will solve some of the infill and closed shape issues I've had. Thanks again - and I will update the post.

ktdreyer said...

Thanks for this tip... just used it in Inkscape 4.5 on WinXP.

Ned Bushell said...

Hey I run Inkscape 0.45.1 for Windows. I get this error when trying to use perspective: Traceback (most recent call last):

File "share\extensions\", line 128, in ?


File "C:\Program Files\Inkscape\share\extensions\", line 157, in affect


File "share\extensions\", line 80, in effect

solmatrix[i][0] = sp[i][0]

UnboundLocalError: local variable 'sp' referenced before assignment

How can I fix it??

RichardQuerin said...

Hi Ned,

Sorry to hear you're having a problem. Sadly, I'm so far from being an inkscape expert it's not even funny! :)

Your question would be perfect for the inkscape developers mailing list. You can find the various inkscape mailing lists here. Sorry I couldn't help you out directly. There is also the inkscape forum that might help you out too.
Good luck.

Marty said...

Great tutorial. I had similar problems in Windows Vista. I changed my program menu shortcut to Inkscape to always run as administrator and it fixed the problem.

Ze Andrade said...

People, I haved the same error posted by Ned Bushell , but i'm using Debian Linux. Now, I reinstall the 0.45.1 version of inkscape without the update the script, and itÅ› working. Ah, one more observation, if we don't tranform an object in a path, a similar error will be displayed or the efect will not apllied.
Sorry for my terrible 'english'.

Anonymous said...

Hey folks,

i'm using vista too and had the same problem as described by ned. i did what marty suggested and now it works! thanks buddy!

Omar Cruz said...

I like your article is fantastic, is really good written. Congratulation!!!. Do you want to see something more? Read it...Zeta Group, Great investment opportunity in Costa Rica: jaco bay. Visit us for more info at: