116 geocode_t rasterType;
117 geocode_t coordSysType;
119 if ((GTIFKeyGet(
m_geotiff, GTModelTypeGeoKey, &modelType, 0, 1) == 1) &&
120 ((modelType == 1) || (modelType == 2))) {
122 if ((GTIFKeyGet(
m_geotiff, GTRasterTypeGeoKey, &rasterType, 0, 1) == 1) &&
123 (rasterType == 1 || rasterType == 2)) {
128 if (GTIFKeyGet(
m_geotiff, ProjectedCSTypeGeoKey, &coordSysType, 0, 1) == 1) {
131 FileName transFile((QString)
"$ISISROOT/appdata/translations/" +
133 if (transFile.fileExists()) {
137 geoTiffCodeTranslater.Auto(outPvl);
145 if (GTIFKeyGet(
m_geotiff, GeographicTypeGeoKey, &geoCode, 0, 1) == 1) {
146 std::cout <<
"GeographicTypeGeoKey = " << geoCode << std::endl;
149 std::cout <<
"no GeographicTypeGeoKey" << std::endl;
152 if (GTIFKeyGet(
m_geotiff, GeogAngularUnitsGeoKey, &geoCode, 0, 1) == 1) {
153 std::cout <<
"GeogAngularUnitsGeoKey = " << geoCode << std::endl;
156 std::cout <<
"no GeogAngularUnitsGeoKey" << std::endl;
159 if (GTIFKeyGet(
m_geotiff, GeogEllipsoidGeoKey, &geoCode, 0, 1) == 1) {
160 std::cout <<
"GeogEllipsoidGeoKey = " << geoCode << std::endl;
163 std::cout <<
"no GeogEllipsoidGeoKey" << std::endl;
166 if (GTIFKeyGet(
m_geotiff, GeogSemiMajorAxisGeoKey, &geoCode, 0, 1) == 1) {
167 std::cout <<
"GeogSemiMajorAxisGeoKey = " << geoCode << std::endl;
170 std::cout <<
"no GeogSemiMajorAxisGeoKey" << std::endl;
173 if (GTIFKeyGet(
m_geotiff, GeogSemiMinorAxisGeoKey, &geoCode, 0, 1) == 1) {
174 std::cout <<
"GeogSemiMinorAxisGeoKey = " << geoCode << std::endl;
177 std::cout <<
"no GeogSemiMinorAxisGeoKey" << std::endl;
180 if (GTIFKeyGet(
m_geotiff, GeogInvFlatteningGeoKey, &geoCode, 0, 1) == 1) {
181 std::cout <<
"GeogInvFlatteningGeoKey = " << geoCode << std::endl;
184 std::cout <<
"no GeogInvFlatteningGeoKey" << std::endl;
187 if (GTIFKeyGet(
m_geotiff, ProjCoordTransGeoKey, &geoCode, 0, 1) == 1) {
188 std::cout <<
"ProjCoordTransGeoKey = " << geoCode << std::endl;
191 std::cout <<
"no ProjCoordTransGeoKey" << std::endl;
194 if (GTIFKeyGet(
m_geotiff, ProjLinearUnitsGeoKey, &geoCode, 0, 1) == 1) {
195 std::cout <<
"ProjLinearUnitsGeoKey = " << geoCode << std::endl;
198 std::cout <<
"no ProjLinearUnitsGeoKey" << std::endl;
201 if (GTIFKeyGet(
m_geotiff, ProjStdParallel1GeoKey, &geoCode, 0, 1) == 1) {
202 std::cout <<
"ProjStdParallel1GeoKey = " << geoCode << std::endl;
205 std::cout <<
"no ProjStdParallel1GeoKey" << std::endl;
208 if (GTIFKeyGet(
m_geotiff, ProjStdParallel2GeoKey, &geoCode, 0, 1) == 1) {
209 std::cout <<
"ProjStdParallel2GeoKey = " << geoCode << std::endl;
212 std::cout <<
"no ProjStdParallel2GeoKey" << std::endl;
215 if (GTIFKeyGet(
m_geotiff, ProjNatOriginLongGeoKey, &geoCode, 0, 1) == 1) {
216 std::cout <<
"ProjNatOriginLongGeoKey = " << geoCode << std::endl;
219 std::cout <<
"no ProjNatOriginLongGeoKey" << std::endl;
222 if (GTIFKeyGet(
m_geotiff, ProjNatOriginLatGeoKey, &geoCode, 0, 1) == 1) {
223 std::cout <<
"ProjNatOriginLatGeoKey = " << geoCode << std::endl;
226 std::cout <<
"no ProjNatOriginLatGeoKey" << std::endl;
229 if (GTIFKeyGet(
m_geotiff, ProjFalseEastingGeoKey, &geoCode, 0, 1) == 1) {
230 std::cout <<
"ProjFalseEastingGeoKey = " << geoCode << std::endl;
233 std::cout <<
"no ProjFalseEastingGeoKey" << std::endl;
236 if (GTIFKeyGet(
m_geotiff, ProjFalseNorthingGeoKey, &geoCode, 0, 1) == 1) {
237 std::cout <<
"ProjFalseNorthingGeoKey = " << geoCode << std::endl;
240 std::cout <<
"no ProjFalseNorthingGeoKey" << std::endl;
243 if (GTIFKeyGet(
m_geotiff, ProjFalseOriginLongGeoKey, &geoCode, 0, 1) == 1) {
244 std::cout <<
"ProjFalseOriginLongGeoKey = " << geoCode << std::endl;
247 std::cout <<
"no ProjFalseOriginLongGeoKey" << std::endl;
250 if (GTIFKeyGet(
m_geotiff, ProjFalseOriginLatGeoKey, &geoCode, 0, 1) == 1) {
251 std::cout <<
"ProjFalseOriginLatGeoKey = " << geoCode << std::endl;
254 std::cout <<
"no ProjFalseOriginLatGeoKey" << std::endl;
257 if (GTIFKeyGet(
m_geotiff, ProjFalseOriginEastingGeoKey, &geoCode, 0, 1) == 1) {
258 std::cout <<
"ProjFalseOriginEastingGeoKey = " << geoCode << std::endl;
261 std::cout <<
"no ProjFalseOriginEastingGeoKey" << std::endl;
264 if (GTIFKeyGet(
m_geotiff, ProjFalseOriginNorthingGeoKey, &geoCode, 0, 1) == 1) {
265 std::cout <<
"ProjFalseOriginNorthingGeoKey = " << geoCode << std::endl;
268 std::cout <<
"no ProjFalseOriginNorthingGeoKey" << std::endl;
271 if (GTIFKeyGet(
m_geotiff, ProjCenterLongGeoKey, &geoCode, 0, 1) == 1) {
272 std::cout <<
"ProjCenterLongGeoKey = " << geoCode << std::endl;
275 std::cout <<
"no ProjCenterLongGeoKey" << std::endl;
278 if (GTIFKeyGet(
m_geotiff, ProjCenterLatGeoKey, &geoCode, 0, 1) == 1) {
279 std::cout <<
"ProjCenterLatGeoKey = " << geoCode << std::endl;
282 std::cout <<
"no ProjCenterLatGeoKey" << std::endl;
285 if (GTIFKeyGet(
m_geotiff, ProjCenterEastingGeoKey, &geoCode, 0, 1) == 1) {
286 std::cout <<
"ProjCenterEastingGeoKey = " << geoCode << std::endl;
289 std::cout <<
"no ProjCenterEastingGeoKey" << std::endl;
292 if (GTIFKeyGet(
m_geotiff, ProjCenterNorthingGeoKey, &geoCode, 0, 1) == 1) {
293 std::cout <<
"ProjCenterNorthingGeoKey = " << geoCode << std::endl;
296 std::cout <<
"no ProjCenterNorthingGeoKey" << std::endl;
299 if (GTIFKeyGet(
m_geotiff, ProjScaleAtNatOriginGeoKey, &geoCode, 0, 1) == 1) {
300 std::cout <<
"ProjScaleAtNatOriginGeoKey = " << geoCode << std::endl;
303 std::cout <<
"no ProjScaleAtNatOriginGeoKey" << std::endl;
306 if (GTIFKeyGet(
m_geotiff, ProjAzimuthAngleGeoKey, &geoCode, 0, 1) == 1) {
307 std::cout <<
"ProjAzimuthAngleGeoKey = " << geoCode << std::endl;
310 std::cout <<
"no ProjAzimuthAngleGeoKey" << std::endl;
313 if (GTIFKeyGet(
m_geotiff, ProjStraightVertPoleLongGeoKey, &geoCode, 0, 1) == 1) {
314 std::cout <<
"ProjStraightVertPoleLongGeoKey = " << geoCode << std::endl;
317 std::cout <<
"no ProjStraightVertPoleLongGeoKey" << std::endl;
320 if (GTIFKeyGet(
m_geotiff, VerticalUnitsGeoKey, &geoCode, 0, 1) == 1) {
321 std::cout <<
"VerticalUnitsGeoKey = " << geoCode << std::endl;
324 std::cout <<
"no VerticalUnitsGeoKey" << std::endl;
348 PvlGroup &mapGroup = outPvl.findGroup(
"Mapping");
349 double pixelResolution = mapGroup[
"PixelResolution"];
350 double trueScaleLat = proj->TrueScaleLatitude();
351 double localRadius = proj->LocalRadius(trueScaleLat);
353 double scale = (2.0 *
Isis::PI * localRadius) / (360.0 * pixelResolution);
357 outPvl.findGroup(
"Mapping").clear();
361 return outPvl.findGroup(
"Mapping");