Transforming rectangular image with bitmaps to trapezoid

Post questions on how to use or achieve an effect in Inkscape.
BWOfficer
Posts: 3
Joined: Thu Jun 04, 2015 8:18 pm

Transforming rectangular image with bitmaps to trapezoid

Postby BWOfficer » Thu Jun 04, 2015 8:44 pm

I am trying to draw a picture that includes a computer monitor. The monitor is tilted slightly back and the drawing viewpoint is about 45 degrees off to the left, so I need to apply a perspective effect. It's easy to do when the monitor screen has just a few simple shapes on it:
[*] draw what I want to be on the monitor screen as if seen exactly square on
[*] duplicate the inside edge of the monitor's frame, which is a trapezoid that looks like a rectangle which has had its top edge skewed a little to the left and the left edge stretched to be longer than the right
[*] use Extensions > Modify Path > Perspective to transform the seen-head-on screen contents

That works fine provided what I want to have on the screen is just some simple lines and shapes (transformed into paths). But when I include some bitmaps in what I want on the monitor screen I can no longer use the perspective transform as above.

I've tried using the matrix transform and that works fine with a group that includes bitmaps but it only seems to let me do horizontal or vertical stretching, rotation and parallel skews. I can't work out how to get it to stretch one side of the group I'm transforming more than the other to transform the original rectangle-framed screen into a trapezoid-framed one. Can matrix transform do this? Should I use a different tool altogether? Or is what I'm trying to do beyond Inkscape's capabilities?

Please note that removing the bitmaps or drawing vector approximations of them is not an option as the bitmaps are too complicated.

If Inkscape can't do it, I suppose I could export the screen element of my drawing as a bitmap then apply transformations using Photoshop Elements' Filter > Correct Camera Distortion tool, then import back into Inkscape!

User avatar
ragstian
Posts: 1181
Joined: Thu Oct 11, 2012 2:44 am
Location: Stavanger-Norway

Re: Transforming rectangular image with bitmaps to trapezoid

Postby ragstian » Thu Jun 04, 2015 11:15 pm

Hi.

Have a look at this threads:
viewtopic.php?f=5&t=13201&hilit=+Lighthouse#p50235

If you can not get it to work please chime back.
Good Luck!
( ͡° ͜ʖ ͡°)
RGDS
Ragnar

BWOfficer
Posts: 3
Joined: Thu Jun 04, 2015 8:18 pm

Re: Transforming rectangular image with bitmaps to trapezoid

Postby BWOfficer » Thu Jun 04, 2015 11:27 pm

Thanks, Ragastian, but none of the methods in that thread seem suitable. The problem is that the group I'm trying to reshape has a mix of vector elements and bitmaps. Extensions > Modify Path > Perspective doesn't work when there are bitmaps. The other techniques discussed in the thread you referred me to seem to involve converting the image you want to reshape into a vector path. I can't do that with a complex bitmap.

Regards,

Bruce Officer

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

Re: Transforming rectangular image with bitmaps to trapezoid

Postby ~suv » Fri Jun 05, 2015 12:33 am

In SVG, bitmap images can't be transformed in such a way.

See this earlier topic Tutorial: Creating a Box in accurate perspective for an example how to use GIMP for the bitmap images, and Inkscape for the vector parts.

BWOfficer
Posts: 3
Joined: Thu Jun 04, 2015 8:18 pm

Re: Transforming rectangular image with bitmaps to trapezoid

Postby BWOfficer » Fri Jun 05, 2015 12:46 am

Thanks for that, ~Suv.

I'll go with my own Plan B, then, which was to do the bitmap transformation in Photoshop Elements 11 (which I already have on my PC). No point in me installing GIMP and spending time learning to use it. In fact, I found that Photoshop Elements' Image > Transform > Distort was the easiest way to reshape the image of what I want to appear on the screen of the monitor I drew, instead of Filter > Correct Camera Distortion. If paste the target trapezoid frame in as a second layer I can easily use that Distort tool to move the four corners of the image onto the respective corners of the trapezoid, and ... le voila! It's done.


Return to “Help with using Inkscape”

Who is online

Users browsing this forum: No registered users and 5 guests