[Gdal-dev] GDAL data model, caching, GDALProjDef

Hannu Koivisto azure at iki.fi
Wed Feb 12 11:08:26 EST 2003


Greetings,

I'm having some difficulties in seeing how to best use GDAL in my
application.  It may be that I'm proceeding exactly as I should,
but I can't help thinking that my data model requirements overlap
GDAL's data model / API slightly and I can't see whether I should
maybe extend GDAL or simply use a smaller subset of its
functionality.  Also, if you have suggestions on higher level
libraries layered on top of GDAL that might be suitable for me, I
am all ears.

I'm working on a navigation application primarily for touring
enduro motorcycling uses; basic moving map with GPS, waypoints,
routes, etc. along the lines of OziExplorer plus some special
features.  Map display is the hardest part (and also the only part
relevant to GDAL use) since I need to handle very large maps and
the software needs to work in handheld computers in addition to
normal desktop ones.  In my primary use case I have a single map
splitted to thousands of 800x800 (or so) PNG files.  PNG because it
seems to compress well in this case and splitted because arbitrary
regions in PNGs cannot be accessed efficiently.  I have separate
overviews, some of which are splitted as well due to their large
sizes.

My initial idea was to simply use GDAL to load each splitted file
(that is currently needed for display and that is not already in
memory) to memory and immediately close the datasets so that GDAL
does not cache anything that I already do.  And manage overviews
and cache data on my own.  However, I guess I could alternatively
create a GDAL driver for such "virtual" maps that are stored to
multiple files and then rely on GDAL's caching and overview
capabilities.  One immediate demerit of this approach is that it is
probably more complicated and the whole map display part, not to
speak about map loading and caching, is something I'd prefer to
offload to an existing library since the non-generic stuff for
which I believe I have something "new" to contribute to is in the
other features.

What would you suggest?

Another thing, the documentation of GDALDataset::GetProjectionRef
refers to GDALProjDef ("The returned string defines the projection
coordinate system of the image in either PROJ.4 format or OpenGIS
WKT format. It should be suitable for use with the GDALProjDef
object to reproject positions").  I couldn't find documentation
about or the implementation of GDALProjDef anywhere.  Am I correct
that it is obsoleted by the OGR library?

-- 
Hannu



More information about the Gdal-dev mailing list