FortranGIS
Version2.5
|
Fortran 2003 interface to the gdal http://www.gdal.org/ library. More...
Data Types | |
interface | gdalapplygeotransform_f |
Interface to a Fortran version of gdalapplygeotransform working on scalars, 1-d, 2-d and 3-d arrays. More... | |
interface | gdaldatasetrasterio_f |
Simplified Fortran generic interface to the gdaldatasetrasterio C function. More... | |
interface | gdalmajorobjecth_new |
Fortran interface for formally converting a dataset, rasterband or driver opaque object into a generic gdal object of type gdalmajorobjecth to be used in some methods such as GDALGetMetadata. More... | |
interface | gdalrasterio_f |
Simplified Fortran generic interface to the gdalrasterio C function. More... | |
Functions/Subroutines | |
subroutine | gdaldatasetbbsize_f (hds, bbxmin, bbymin, bbxmax, bbymax, nx, ny, offsetx, offsety, xmin, ymin, xmax, ymax) |
Determine the size of a dataset subset. More... | |
subroutine | gdaldatasetsimpleread_f (hds, bbxmin, bbymin, bbxmax, bbymax, pbuffer, xmin, ymin, xmax, ymax) |
Even more simplified method for importing data from a dataset within a bounding box specified in georeferenced coordinates. More... | |
subroutine | gdalrastersimpleread_f (hband, bbxmin, bbymin, bbxmax, bbymax, pbuffer, xmin, ymin, xmax, ymax) |
Even more simplified method for importing data from a raster band within a bounding box specified in georeferenced coordinates. More... | |
Variables | |
integer(kind=c_int), parameter | gdt_unknown = 0 |
constant defining the native data type of a dataset data: unknown More... | |
integer(kind=c_int), parameter | gdt_byte = 1 |
byte, in Fortran it can be declared as INTEGER(kind=C_INT_8_T) More... | |
integer(kind=c_int), parameter | gdt_uint16 = 2 |
unsigned 16 bit integer, it should be avoided in Fortran and translated into a signed type More... | |
integer(kind=c_int), parameter | gdt_int16 = 3 |
signed 16 bit integer, in Fortran it can be declared as INTEGER(kind=C_INT_16_T) More... | |
integer(kind=c_int), parameter | gdt_uint32 = 4 |
unsigned 32 bit integer, it should be avoided in Fortran and translated into a signed type More... | |
integer(kind=c_int), parameter | gdt_int32 = 5 |
signed 32 bit integer, in Fortran it can be declared as INTEGER(kind=C_INT) More... | |
integer(kind=c_int), parameter | gdt_float32 = 6 |
32 bit floating point real, in Fortran it can be declared as REAL(kind=C_FLOAT) More... | |
integer(kind=c_int), parameter | gdt_float64 = 7 |
64 bit floating point real, in Fortran it can be declared as REAL(kind=C_DOUBLE) More... | |
integer(kind=c_int), parameter | gdt_cint16 = 8 |
16 bit integer complex, it should be avoided in Fortran and translated into a floating point type More... | |
integer(kind=c_int), parameter | gdt_cint32 = 9 |
32 bit integer complex, it should be avoided in Fortran and translated into a floating point type More... | |
integer(kind=c_int), parameter | gdt_cfloat32 = 10 |
32 bit (*2) floating point complex, in Fortran it can be declared as COMPLEX(kind=C_FLOAT_COMPLEX) More... | |
integer(kind=c_int), parameter | gdt_cfloat64 = 11 |
64 bit (*2) floating point complex, in Fortran it can be declared as COMPLEX(kind=C_DOUBLE_COMPLEX) More... | |
integer(kind=c_int), parameter | ga_readonly = 0 |
access type for opening a file: read only More... | |
integer(kind=c_int), parameter | ga_update = 1 |
update More... | |
integer(kind=c_int), parameter | gf_read = 0 |
operation to be performed on a dataset: read More... | |
integer(kind=c_int), parameter | gf_write = 1 |
write More... | |
Fortran 2003 interface to the gdal http://www.gdal.org/ library.
This module includes the interface to most of the public gdal C API plus a more "Fortranic" version of some functions.
The following functions are directly interfaced to their corresponding C version, so they are undocumented here, please refer to the original gdal C API documentation, e.g. at the address http://www.gdal.org/gdal_8h.html , for their use:
As a general guideline, note that when a char**
object is encountered in the C interface, it should usually be interfaced in Fortran by means of the fortranc::c_ptr_ptr derived type.
Other Fortran-style subroutines, functions and procedure interfaces are documented explicitely here.
For an example of application of the gdal module, please refer to the following test program, which creates a very simple gdal raster dataset, exports it on a GEOTiff file and successively reads it: