# TikZ trapezoid transformation (vanishing point) [closed]

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.

-
Welcome to TeX.sx! No need to add signature, your username is included in the lower right of your Q. –  Peter Jansson Jan 28 at 23:42
The transformation you achieved would be the result of a parallel projection. You actually want to simulate a perspective projection? I don’t think this is doable with vanilla TikZ options. You probably need to calculate these transformations. –  Qrrbrbirlbel Jan 28 at 23:46
This is not doable via PDF transformation (TikZ and PGF use PDF transformations). You need to transform your rasterimage via Gimp (or Photoshop). –  Paul Gaborit Jan 29 at 0:13
Maybe a duplicate : tex.stackexchange.com/questions/52578/perspective-transform ? Nope you have an image, nevermind –  percusse Jan 29 at 0:32
Maybe you could draw your rectangle in perspective using the 3D capabilities of Tikz? See tex.stackexchange.com/q/59406/19156 –  Lionel MANSUY Jan 29 at 8:58
show 1 more comment

## closed as too localized by Qrrbrbirlbel, Heiko Oberdiek, Kurt, Xavier, Tom BombadilJun 10 at 4:40

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.