\documentclass{article}
\usepackage{graphicx}
\usepackage{tikz}
\newcommand*{\SlantedImage}[3][]{%
\begingroup
\sbox0{\includegraphics[{#1}]{#3}}%
\pgfmathsetmacro\xslant{tan(#2)}%
\edef\ImageHeight{\the\dimexpr\dp0+\ht0}%
\pgfmathsetlengthmacro\ImageWidth{\wd0 + \ImageHeight*\xslant}%
\sbox0{%
\tikz[
inner sep=0pt,
baseline=(current bounding box.south),
transform canvas={xslant=\xslant},
]\node[above right]{\copy0};%
}%
\wd0=\ImageWidth\relax
\ht0=\ImageHeight\relax
\usebox{0}%
\endgroup
}
\begin{document}