Changes between Initial Version and Version 1 of rfc4_geolocate


Ignore:
Timestamp:
Apr 28, 2007, 12:05:08 PM (17 years ago)
Author:
warmerdam
Comment:

Ported from doxygen.

Legend:

Unmodified
Added
Removed
Modified
  • rfc4_geolocate

    v1 v1  
     1= RFC 4: Geolocation Arrays =
     2
     3Author: Frank Warmerdam[[BR]]
     4Contact: warmerdam@pobox.com[[BR]]
     5Status: Development
     6
     7== Summary ==
     8
     9It is proposed that GDAL support an additional mechanism for geolocation
     10of imagery based on large arrays of points associating pixels and lines
     11with geolocation coordinates.  These arrays would be represented as raster
     12bands themselves.
     13
     14It is common in AVHRR, Envisat, HDF and netCDF data products to distribute
     15geolocation for raw or projected data in this manner, and current approaches
     16to representing this as very large numbers of GCPs, or greatly subsampling
     17the geolocation information to provide more reasonable numbres of GCPs are
     18inadequate for many applications.
     19
     20== Geolocation Domain Metadata ==
     21
     22Datasets with geolocation information will include the following dataset level
     23metadata items in the "GEOLOCATION" domain to identify the geolocation arrays,
     24and the details of the coordinate system and relationship back to the original
     25pixels and lines.
     26
     27 * SRS: wkt encoding of spatial reference system.
     28 * X_DATASET: dataset name (defaults to same dataset if not specified)
     29 * X_BAND: band number within X_DATASET.
     30 * Y_DATASET: dataset name (defaults to same dataset if not specified)
     31 * Y_BAND: band number within Y_DATASET.
     32 * Z_DATASET: dataset name (defaults to same dataset if not specified)
     33 * Z_BAND: band number within Z_DATASET. (optional)
     34 * PIXEL_OFFSET: pixel offset into geo-located data of left geolocation pixel
     35 * LINE_OFFSET: line offset into geo-located data of top geolocation pixel
     36 * PIXEL_STEP: each geolocation pixel represents this many geolocated pixels.
     37 * LINE_STEP: each geolocation pixel represents this many geolocated lines.
     38
     39In the common case where two of the bands of a dataset are actually
     40latitude and longitude, and so the geolocation arrays are the same size as
     41the base image, the metadata might look like:
     42
     43{{{
     44SRS: GEOGCS...
     45X_BAND: 2
     46Y_BAND: 3
     47PIXEL_OFFSET: 0
     48LINE_OFFSET: 0
     49PIXEL_STEP: 1
     50LINE_STEP: 1
     51}}}
     52
     53For AVHRR datasets, there are only 11 points, but for every line.  So
     54the result for a LAC dataset might look like:
     55
     56{{{
     57SRS: GEOGCS...
     58X_DATASET: L1BGCPS:n12gac10bit.l1b
     59X_BAND: 1
     60Y_DATASET: L1BGCPS:n12gac10bit.l1b
     61Y_BAND: 2
     62PIXEL_OFFSET: 25
     63LINE_OFFSET: 0
     64PIXEL_STEP: 40
     65LINE_STEP: 1
     66}}}
     67
     68This assumes the L1B driver is modified to support the special access
     69to GCPs as bands using the L1BGCPS: prefix.
     70
     71== Updating Drivers ==
     72
     73
     74 1. HDF4: Client needs mandate immediate incorporation of geolocation array support in the HDF4 driver (specifially for swath products).  (complete)
     75 2. HDF5: Some HDF5 products include geolocation information that should be handled as arrays.  No timetable for update.
     76 3. AVHRR: Has 11 known location per-scanline.  These are currently substantially downsampled and returned as GCPs, but this format would be an excellent canidate for treating as geolocation arrays.  Planned in near future.
     77 4. Envisat: Envisat raw products use geolocation information currently subsampled as GCPs, good candidate for upgrade.   No timetable for update.
     78 5. netCDF: NetCDF files can have differently varying maps in x and y directions which could be represented as geolocation arrays when they are irregular.   No timetable for update.
     79 6. OPeNDAP: Can have differently varying maps in x and y directions which could be represented as geolocation arrays when they are irregular.   No timetable for update.
     80
     81== Changes to Warp API and gdalwarp ==
     82
     83Introduce a new geolocation array based transformation method, following the
     84existing GDALTransformer mechanism.  A geolocation array transformer will
     85be created with the following function call.  The "char **" array is the
     86list of metadata from the GEOLOCATION metadata domain.
     87
     88{{{
     89 void *GDALCreateGeoLocTransformer( GDALDatasetH hBaseDS,
     90                                    char **papszGeolocationInfo,
     91                                    int bReversed );
     92}}}
     93
     94This transformer is currently partially implemented, but in a manner that
     95potentially uses a great deal of memory (twice the memory needed for the
     96geolocation arrays), and with still dubious correctness, but once approved
     97this will be fixup up to at least be correct, though likely not efficient for
     98the time being.
     99
     100The GDALGenImgProjTransformer will be upgraded to instantiate the GeoLoc
     101transformer (instead of an affine, gcp, or rpc transformer) if only
     102geolocation information is available (done).  However, the current
     103GDALCreateGenImgProjTransformer() function does not provide a mechanism to
     104select which transformation mechanism is used.  So, for instance, if an
     105affine transform is available it will be used in preference to geolocation
     106data.  If bGCPUseOK is TRUE, gcps will be used in preference to geolocation
     107data. 
     108
     109The gdalwarp program currently always sets bGCPUseOK to TRUE so there
     110is no means for gdalwarp users select use of geolocation data in preference
     111to gcps.  Some modification to gdalwarp may be needed in the future in this
     112regard.
     113
     114== Preserving Geolocation Through Translation ==
     115
     116''How do we preserve access to geolocation information when translating
     117a dataset?  Do applications like gdal_translate need special handling? 
     118Placement of the geolocation data in a special metadata domain means it
     119won't be transferred in default translations.''
     120