[R-sig-Geo] Including SAGA grid as GDAL-supported format

Tomislav Hengl hengl at spatial-analyst.net
Sat Oct 17 10:28:00 CEST 2009


> -----Original Message-----
> From: Roger Bivand [mailto:Roger.Bivand at nhh.no]
> Sent: Friday, October 16, 2009 11:06 AM
> To: Tomislav Hengl
> Cc: r-sig-geo at stat.math.ethz.ch
> Subject: Re: [R-sig-Geo] Including SAGA grid as GDAL-supported format
> 
> On Fri, 16 Oct 2009, Tomislav Hengl wrote:
> 
> >
> > Dear r-sig-geo,
> >
> > I would like to initiate the processes of registering the SAGA grid format
> > under GDAL (the SAGA 2.0.4 source code is available for download here
> > http://sourceforge.net/projects/saga-gis/files/SAGA%20-
> %202.0/SAGA%202.0.4/saga_2.0.4_src.zip/download).
> >
> > Do I have to follow some formal procedure, or do I have to prepare the GDAL
> > driver myself (as explained at http://www.gdal.org/gdal_drivertut.html)? Any
> > help/suggestions are welcome (apparently it should not be too complicated).
> 
> Tom,
> 
> Writing a read-only driver would be the first step. Once that works, it
> could be extended to copy creation, and finally to direct creation if
> justified. If SAGA I/O has a separate I/O library, it could be shipped
> with the driver as in the pcraster driver, but I don't see one in the
> source tree. Writing a driver for SAGA rasters would permit lots of other
> software to interact with SAGA, not just in R, so would be more robust.
> 
> You'd develop on a local copy of the GDAL source, and once done submit a
> file archive of the directory to Frank Warmerdam or other GDAL people.
> Maybe ask on the GDAL developers' list if they have seen questions about
> SAGA rasters before. Are SAGA rasters similar to any existing supported
> formats (Erdas?, IDRISI?, ILWIS?) - could an existing driver be copied and
> modified?

Roger,

I've got an reply from FW who suggested that I should used the existing "raw file + ascii header"
drivers as a template:

http://svn.osgeo.org/gdal/trunk/gdal/frmts/raw/genbindataset.cpp

We could try adopting this to see it will work with SAGA grids also.

Apparently Volker Wichmann started implementing the SAGA driver himself (this summer), but then
never finished (he might send me his code).

Thanks for your suggestions and clarifications.

Tom

> 
> Roger
> 
> >



More information about the R-sig-Geo mailing list