<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from rtf -->
<style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
</head>
<body>
<font face="Calibri" size="2"><span style="font-size:11pt;">
<div>Hi,</div>
<div>A very newbie, Zurich/Win10.</div>
<div>Imported my photos into QGIS, used Display <font color="#4472C4"><img src="<a href=""></a>file:///[% photo %]" width="350" height="250"/></font>, toggled Map Notes, added single label, all worked fine.</div>
<div>Except my photos are landscape but some are portrait.</div>
<div>QGIS strips out most of the photo metadata but leaves Fields “photo” (combined path and filename) and “rotation” which is either 90 or 0 amongst others. NB: QGIS put Fields Long then Lat but other GPS software expect Lat then Lon.</div>
<div>So as QGIS Expression has an IF THEN function is should be possible to check which “rotation” and change width and height accordingly.</div>
<div>But I know QGIS syntax is very picky, so cannot stumble in the dark trying to guess how the expression should go.</div>
<div>I guess something along the lines of:</div>
<div><font color="#4472C4"><img src=if(“rotate”=0, "<a href=""></a>file:///[% photo %]" width="350" height="250","<a href=""></a>file:///[% photo %]" width="250" height="350")/></font></div>
<div>Can anyone please tell me what I need to change please.</div>
<div>Tony</div>
<div> </div>
<div> </div>
</span></font>
</body>
</html>