<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
Kirk,<br>
<p>Yes if there's an EPSG code for the CRS, GDAL avoids going
through defining all the parameters. That limits the risk of
self-contradicting definitions, and readers being confused by what
is authoritative.</p>
<p>The following (untested (TM)) patch should accomplish what you
want:</p>
<p>diff --git a/frmts/gtiff/gt_wkt_srs.cpp
b/frmts/gtiff/gt_wkt_srs.cpp<br>
index 22eabfcd38..5a089142f8 100644<br>
--- a/frmts/gtiff/gt_wkt_srs.cpp<br>
+++ b/frmts/gtiff/gt_wkt_srs.cpp<br>
@@ -2213,7 +2213,8 @@ int GTIFSetFromOGISDefnEx(GTIF *psGTIF,
OGRSpatialReferenceH hSRS,<br>
GTIFKeySet(psGTIF, ProjectedCSTypeGeoKey, TYPE_SHORT,
1, nPCS);<br>
}<br>
}<br>
- else if (poSRSCompatibleOfWKT1->IsGeocentric())<br>
+<br>
+ if (poSRSCompatibleOfWKT1->IsGeocentric())<br>
{<br>
GTIFKeySet(psGTIF, GTModelTypeGeoKey, TYPE_SHORT, 1,<br>
ModelTypeGeocentric);<br>
</p>
<br>
<p>Even<span style="white-space: pre-wrap">
</span></p>
<pre class="moz-signature" cols="72">--
<a class="moz-txt-link-freetext" href="http://www.spatialys.com">http://www.spatialys.com</a>
My software is free, but my time generally not.
Butcher of all kinds of standards, open or closed formats. At the end, this is just about bytes.
Mood of the day: "Bien entendu, on peut sauter sur sa chaise comme un cabri en disant : les standards ! les standards ! les standards ! Mais ça n’aboutit à rien et ça ne signifie rien." ~ dixit De Gaulle</pre>
</body>
</html>