"John Clonts" wrote in message ...
"Kyler Laird" wrote in message
...
"John Clonts" writes:
Thanks for the tips. I found that when I use the "raw data" it does work
as
you say (http://aviationtoolbox.org/raw_data/...onals/current/).
Is
this what you are using?
But I have trouble when I try to use one of Kyler's "processed images"
from
https://aviationtoolbox.org/Members/...s/map_explorer
I have the problems that J.G. diagnoses below.
TIFF Directory at offset 0x15ff3e
Image Width: 800 Image Length: 600
Bits/Sample: 8
Sample Format: unsigned integer
Compression Scheme: None
Photometric Interpretation: RGB color
Samples/Pixel: 3
Rows/Strip: 10
Planar Configuration: separate image planes
Tag 33550: 128.000000,128.000000,0.000000
.
.
It's that Planar Configuration setting of "separate image planes"
that is confusing Ozi. Ozi wants to see "single image plane".
Ah ha! That was causing problems for ImageMagick too. I just didn't
realize that's what was doing it.
http://www.remotesensing.org/gdal/frmt_gtiff.html
INTERLEAVE=[BAND,PIXEL]: By default TIFF files with band
interleaving (PLANARCONFIG_SEPARATE in TIFF terminology) are
created. These are slightly more efficient for some purposes,
but some applications only support pixel interleaved TIFF
files. In these cases pass INTERLEAVE=PIXEL to produce pixel
interleaved TIFF files (PLANARCONFIG_CONTIG in TIFF
terminology).
So...I added "INTERLEAVE=PIXEL" and now tiffinfo reports this.
TIFF Directory at offset 0x580a1e
Image Width: 1600 Image Length: 1200
Bits/Sample: 8
Sample Format: unsigned integer
Compression Scheme: None
Photometric Interpretation: RGB color
Samples/Pixel: 3
Rows/Strip: 1
Planar Configuration: single image plane
ImageMagick displays a beautiful image now too.
Does that solve the problem you had?
Thank you for the report.
Kyler,
Thanks that does solve the image display problem!
The other problem remains however: the georeference information is not read
in successfully by Oziexplorer:
The example which works is e.g. the San Antonio Sectional at
http://aviationtoolbox.org/raw_data/...73%20North.tif
:
Its listgeo info is:
Geotiff_Information:
Version: 1
Key_Revision: 1.0
Tagged_Information:
ModelTiepointTag (2,3):
0 0 0
-364619.149 238513.594 0
ModelPixelScaleTag (1,3):
63.781518 63.781518 0
End_Of_Tags.
Keyed_Information:
GTModelTypeGeoKey (Short,1): ModelTypeProjected
GTRasterTypeGeoKey (Short,1): RasterPixelIsArea
GTCitationGeoKey (Ascii,235): "IMAGINE GeoTIFF Support
Copyright 1991 - 2001 by ERDAS, Inc. All Rights Reserved
@(#)$RCSfile: egtf.c $ $Revision: 1.9.2.4 $ $Date: 2002/01/24 16:43:13Z $
Projection Name = Lambert Conformal Conic
Units = meters
GeoTIFF Units = meters"
GeographicTypeGeoKey (Short,1): GCS_NAD83
ProjectedCSTypeGeoKey (Short,1): User-Defined
PCSCitationGeoKey (Ascii,192): "IMAGINE GeoTIFF Support
Copyright 1991 - 2001 by ERDAS, Inc. All Rights Reserved
@(#)$RCSfile: egtf.c $ $Revision: 1.9.2.4 $ $Date: 2002/01/24 16:43:13Z $
Projection = Lambert Conformal Conic"
ProjectionGeoKey (Short,1): User-Defined
ProjCoordTransGeoKey (Short,1): CT_LambertConfConic_2SP
ProjLinearUnitsGeoKey (Short,1): Linear_Meter
ProjStdParallel1GeoKey (Double,1): 30.6666667
ProjStdParallel2GeoKey (Double,1): 25.3333333
ProjNatOriginLongGeoKey (Double,1): -100
ProjFalseOriginLongGeoKey (Double,1): 0
ProjFalseOriginLatGeoKey (Double,1): 30.125
ProjFalseOriginEastingGeoKey (Double,1): 0
ProjFalseOriginNorthingGeoKey (Double,1): 0
End_Of_Keys.
End_Of_Geotiff.
Projection Method: CT_LambertConfConic_2SP
ProjStdParallel1GeoKey: 30.666667 ( 30d40' 0.00"N)
ProjStdParallel2GeoKey: 25.333333 ( 25d20' 0.00"N)
ProjFalseOriginLatGeoKey: 30.125000 ( 30d 7'30.00"N)
ProjFalseOriginLongGeoKey: -100.000000 (100d 0' 0.00"W)
ProjFalseEastingGeoKey: 0.000000
ProjFalseNorthingGeoKey: 0.000000
GCS: 4269/NAD83
Datum: 6269/North American Datum 1983
Ellipsoid: 7019/GRS 1980 (6378137.00,6356752.31)
Prime Meridian: 8901/Greenwich (0.000000/ 0d 0' 0.00"E)
Projection Linear Units: 9001/metre (1.000000m)
Corner Coordinates:
Upper Left (-364619.149, 238513.594) (103d51'44.46"W, 32d13'23.18"N)
Lower Left (-364619.149, -26434.831) (103d46'31.88"W, 29d50' 7.76"N)
Upper Right ( 343419.482, 238513.594) ( 96d21'43.48"W, 32d13'44.30"N)
Lower Right ( 343419.482, -26434.831) ( 96d26'37.91"W, 29d50'28.46"N)
Center ( -10599.834, 106039.382) (100d 6'39.75"W, 31d 4'53.35"N)
The example that does not work is:
https://aviationtoolbox.org/Members/...ul_Y=-676347.0
And its listgeo info is:
Geotiff_Information:
Version: 1
Key_Revision: 1.0
Tagged_Information:
ModelTiepointTag (2,3):
0 0 0
216057 -676347 0
ModelPixelScaleTag (1,3):
128 128 0
End_Of_Tags.
Keyed_Information:
GTModelTypeGeoKey (Short,1): ModelTypeProjected
GTRasterTypeGeoKey (Short,1): RasterPixelIsArea
GTCitationGeoKey (Ascii,8): "unnamed"
GeographicTypeGeoKey (Short,1): GCS_NAD83
ProjectedCSTypeGeoKey (Short,1): User-Defined
ProjectionGeoKey (Short,1): User-Defined
ProjCoordTransGeoKey (Short,1): CT_LambertConfConic_2SP
ProjLinearUnitsGeoKey (Short,1): Linear_Meter
ProjStdParallel1GeoKey (Double,1): 38.6666667
ProjStdParallel2GeoKey (Double,1): 33.3333333
ProjFalseEastingGeoKey (Double,1): 0
ProjFalseNorthingGeoKey (Double,1): 0
ProjFalseOriginLongGeoKey (Double,1): -100.583333
ProjFalseOriginLatGeoKey (Double,1): 38
End_Of_Keys.
End_Of_Geotiff.
Projection Method: CT_LambertConfConic_2SP
ProjStdParallel1GeoKey: 38.666667 ( 38d40' 0.00"N)
ProjStdParallel2GeoKey: 33.333333 ( 33d20' 0.00"N)
ProjFalseOriginLatGeoKey: 38.000000 ( 38d 0' 0.00"N)
ProjFalseOriginLongGeoKey: -100.583333 (100d35' 0.00"W)
ProjFalseEastingGeoKey: 0.000000
ProjFalseNorthingGeoKey: 0.000000
GCS: 4269/NAD83
Datum: 6269/North American Datum 1983
Ellipsoid: 7019/GRS 1980 (6378137.00,6356752.31)
Prime Meridian: 8901/Greenwich (0.000000/ 0d 0' 0.00"E)
Projection Linear Units: 9001/metre (1.000000m)
Corner Coordinates:
Upper Left ( 216057.000,-676347.000) ( 98d18'10.89"W, 31d52'40.87"N)
Lower Left ( 216057.000,-753147.000) ( 98d19'18.60"W, 31d11'12.79"N)
Upper Right ( 318457.000,-676347.000) ( 97d13'22.77"W, 31d51' 4.80"N)
Lower Right ( 318457.000,-753147.000) ( 97d15' 2.51"W, 31d 9'37.59"N)
Center ( 267257.000,-714747.000) ( 97d46'28.56"W, 31d31'13.34"N)
They both look pretty good to me-- the corner coordinates seem to be there,
etc-- but I don't know anything about all the "false origin" stuff.
Oziexplorer doesn't seem to have trouble with the Lambert projection in the
first example though.
I am copying this to the OziUsers List, maybe J.G. can give some more
assistance?
Kyler,
This is the input I got from J.G. on the OziUsers list, regarding the
above:
begin quote
I took a look at the goetiff tags for the two images and I think I
see the problem. The full image is specifying a key:
ProjNatOriginLongGeoKey (Double,1): -100
While the smaller image does not even have that key. Somehow, the
smaller image is using the tag:
ProjFalseOriginLongGeoKey (Double,1): -100.583333
These can't both be right. I'd say the full image is the right one,
since it loads fine in not just Ozi, but other programs too, while
the smaller image does not work in other programs. I'm pretty
certain that the ProjNatOriginLongGeoKey is only supposed to be used
in cases where the prime meridian is not the familiar 0 degrees
longitude value. Technically, the math may work, to subvert the
function of that tag and then specify the ProjFalseOriginLongGeoKey
as 0.0, but it's highly irregular. Listgeo is able to deal with it,
by translating the natorigin key to it's equivalent falseorigin key,
but programs generating geotiff files should not rely on geotiff
readers to do this.
All that said, you can fix these keys. If you redirect the output of
the listgeo program to a file, you can edit that file with any
ordinary text editor and reinstall it into the geotiff file, using
the geotifcp program, which is part of the zip file I referred to
previously.
J.G.
end quote
By full image he means the San Antonio sectional ("raw"), and by
"smaller image" he means the one provided by your map_explorer link...
Hope that helps,
John