Within a TikZ drawing, I want to distort a 2D rasterimage (from
\includegraphics) so that it appears to be rotated by 90° around the
vertical axis in 3D (it should look perpendicular to the sheet of
paper). I've managed to achieve a transformation with yslant and
xscale, like the following.
\begin{tikzpicture}
\node (term) at (0,0) [yslant=-0.7,xscale=0.3]
{\includegraphics[width=40mm]{image.png}};
\end{tikzpicture}
which distorts an image like this
a
|\
a---------b | \
| | | \
| | --> c b
| | \ |
c---------d \ |
\|
d
I'm not really happy with this: The distance |a-c| should be smaller than |b-d|. How can I achieve this?
There is an example of a cuboid which looks pretty nice, but it seems useless to distort an imported raster image.
example-image.pngfrom themwepackage one can doconvert example-image.png -distort Perspective "0,0,0,40 0,300,0,260 400,0,400,0 400,300,400,300" example-image-distorted.png. Though, I couldn’t get the now black background color to be either white or transparent. I’m sure, it is somehow possible. – Qrrbrbirlbel Apr 09 '13 at 17:02