comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: how to composite a mapcoord object using geographic coordinate(no projection)
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: how to composite a mapcoord object using geographic coordinate(no projection) [message #87712 is a reply to message #87710] Tue, 25 February 2014 01:25 Go to previous messageGo to previous message
Yngvar Larsen is currently offline  Yngvar Larsen
Messages: 134
Registered: January 2010
Senior Member
On Tuesday, 25 February 2014 00:48:48 UTC+1, David Fanning wrote:
> Fabien writes:
>
>
>
>> I believe that these are also "standard" formats but less transparent.

These files are indeed TIFF 6.0 conformant, but the information in them do not contain enough GeoTIFF tags to have a uniquely defined grid without external information. Thus, you need ugly special cases in your GeoTIFF reader to handle this. Or a specific reader for each. I did the latter for SRTM tiles, which only contain "ModelPixelScaleTag" and "ModelTiepointTag", but no info on the coordinate system.

> I don't know. I've seen three files in the past three days that purport
> to be "GeoTiff" files, and not a one of them appears to have been
> written by someone who read the TIFF definitions and standards document.

You should not confuse GeoTIFF with TIFF. A conformant TIFF file can contain almost any imaginable tags/metadata (or not...). However, such extra information can be ignored a conformant TIFF _reader_. GeoTIFF is such extra information.

GCS_WGS_84 = 4326

> Can you just make it up and call it a GeoTiff?

I guess you can use at least one of the defined GeoTIFF tags, and call it a GeoTIFF file. But if you would like your file to be self contained, I would say you should at least follow the cookbooks in the spec:

http://www.remotesensing.org/geotiff/spec/geotiff2.6.html#2. 6.3
http://www.remotesensing.org/geotiff/spec/geotiff2.7.html#2. 7.3

Specifically, for the geographic coordinate systems discussed in this thread, you should do the following

"
case GEOGRAPHIC: Check the list of standard GCS's and use the
corresponding code. To use a code both the Datum, Prime
Meridian, and angular units must match those of the code.

Store in: GeographicTypeGeoKey and skip to Step 4.
If none of the coded GCS's match exactly, then this is a
user-defined GCS. Check the list of standard datums,
Prime Meridians, and angular units to define your system.
Store in: GeogGeodeticDatumGeoKey, GeogAngularUnitsGeoKey,
GeogPrimeMeridianGeoKey and skip to Step 4.

If none of the datums match your system, you have a
user-defined datum, which is an odd system, indeed. Use
the GeogEllipsoidGeoKey to select the appropriate ellipsoid
or use the GeogSemiMajorAxisGeoKey, GeogInvFlatteningGeoKey to
define, and give a reference using the GeogCitationGeoKey.
Store in: GeogEllipsoidGeoKey, etc. and go to Step 4.
"

The file that J. Zhou sent you contain the following information on the coordinate system:

GEOGRAPHICTYPEGEOKEY
INT 4326
GEOGANGULARUNITSGEOKEY
INT 9102
which means a standard GCS (WGS-84) and angular units (degrees) plus
GTMODELTYPEGEOKEY
INT 2
GTRASTERTYPEGEOKEY
INT 1
which means Geographical coordinate system with "PixelIsArea". Thus, this is a well defined self contained GeoTIFF file as far as I understand. On the other hand, the SRTM tile I sent you did not contain any of this, and needs special treatment with external information.

--
Yngvar
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: ps_start output
Next Topic: how to composite a mapcoord object using geographic coordinate(no projection)

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 19:31:37 PDT 2025

Total time taken to generate the page: 0.00482 seconds