|
isce3 0.25.0
|
Wrapper for GDALDataset representing a collection of associated Raster bands. More...
#include <Dataset.h>
Public Member Functions | |
| Dataset (const std::string &path, GDALAccess access=GA_ReadOnly) | |
| Open an existing file as a GDAL dataset. | |
| Dataset (const isce3::io::IDataSet &dataset, GDALAccess access=GA_ReadOnly) | |
| Create a dataset from an HDF5 dataset. | |
| Dataset (const std::string &path, int width, int length, int bands, GDALDataType datatype, const std::string &driver=defaultDriver()) | |
| Create a new GDAL dataset. | |
| Dataset (const std::string &path, const Dataset &src) | |
| Create a new GDAL dataset as a copy of an existing dataset. | |
| Dataset (const std::string &path, const Dataset &src, const std::string &driver) | |
| Create a new GDAL dataset as a copy of an existing dataset. | |
| template<typename T> | |
| Dataset (const T *data, int width, int length, int bands) | |
| Create a read-only dataset describing an existing in-memory array. | |
| template<typename T> | |
| Dataset (T *data, int width, int length, int bands, GDALAccess access=GA_Update) | |
| Create a dataset describing an existing in-memory array. | |
| template<typename T> | |
| Dataset (const T *data, int width, int length, int bands, std::size_t colstride, std::size_t rowstride, std::size_t bandstride) | |
| Create a read-only dataset describing an existing in-memory array. | |
| template<typename T> | |
| Dataset (T *data, int width, int length, int bands, std::size_t colstride, std::size_t rowstride, std::size_t bandstride, GDALAccess access=GA_Update) | |
| Create a dataset describing an existing in-memory array. | |
| GDALAccess | access () const |
| Access mode. | |
| int | width () const |
| Number of columns. | |
| int | length () const |
| Number of rows. | |
| int | bands () const |
| Number of bands. | |
| std::string | driver () const |
| Driver name. | |
| Raster | getRaster (int band) const |
| Fetch raster band. | |
| GeoTransform | getGeoTransform () const |
| Get transform from raster coordinates (pixel, line) to projected coordinates (x, y) | |
| void | setGeoTransform (const GeoTransform &) |
| Set geotransform. | |
| isce3::core::ProjectionBase * | getProjection () const |
| Get spatial reference system. | |
| void | setProjection (const isce3::core::ProjectionBase *) |
| Set spatial reference system. | |
| double | x0 () const |
| Left edge of left-most pixel in projection coordinates. | |
| double | y0 () const |
| Upper edge of upper-most line in projection coordinates. | |
| double | dx () const |
| Pixel width in projection coordinates. | |
| double | dy () const |
| Line height in projection coordinates. | |
| GDALDataset * | get () |
| Get the underlying GDALDataset pointer. | |
| const GDALDataset * | get () const |
| Get the underlying GDALDataset pointer. | |
Static Public Member Functions | |
| static std::string | defaultDriver () |
| Default GDAL driver for dataset creation. | |
Friends | |
| class | Raster |
Wrapper for GDALDataset representing a collection of associated Raster bands.
| isce3::io::gdal::Dataset::Dataset | ( | const std::string & | path, |
| GDALAccess | access = GA_ReadOnly ) |
Open an existing file as a GDAL dataset.
| [in] | path | File path |
| [in] | access | Access mode |
| isce3::io::gdal::Dataset::Dataset | ( | const isce3::io::IDataSet & | dataset, |
| GDALAccess | access = GA_ReadOnly ) |
Create a dataset from an HDF5 dataset.
The resulting dataset is invalidated if the HDF5 file is closed.
| [in] | dataset | HDF5 dataset |
| [in] | access | Access mode |
| isce3::io::gdal::Dataset::Dataset | ( | const std::string & | path, |
| int | width, | ||
| int | length, | ||
| int | bands, | ||
| GDALDataType | datatype, | ||
| const std::string & | driver = defaultDriver() ) |
Create a new GDAL dataset.
| [in] | path | File path |
| [in] | width | Number of columns |
| [in] | length | Number of rows |
| [in] | bands | Number of bands |
| [in] | datatype | Data type identifier |
| [in] | driver | GDAL driver name |
| isce3::io::gdal::Dataset::Dataset | ( | const std::string & | path, |
| const Dataset & | src ) |
Create a new GDAL dataset as a copy of an existing dataset.
The duplicate is created with the same driver format as the original.
| [in] | path | File path of new dataset |
| [in] | src | Source dataset |
| isce3::io::gdal::Dataset::Dataset | ( | const std::string & | path, |
| const Dataset & | src, | ||
| const std::string & | driver ) |
Create a new GDAL dataset as a copy of an existing dataset.
| [in] | path | File path of new dataset |
| [in] | src | Source dataset |
| [in] | driver | GDAL driver name |
|
inline |
Create a read-only dataset describing an existing in-memory array.
The data layout is assumed to be in row major, band sequential format.
| [in] | data | Pointer to first pixel of first band |
| [in] | width | Number of columns |
| [in] | length | Number of rows |
| [in] | bands | Number of bands |
|
inline |
Create a dataset describing an existing in-memory array.
The data layout is assumed to be in row major, band sequential format.
| [in] | data | Pointer to first pixel of first band |
| [in] | width | Number of columns |
| [in] | length | Number of rows |
| [in] | bands | Number of bands |
| [in] | access | Access mode |
|
inline |
Create a read-only dataset describing an existing in-memory array.
| [in] | data | Pointer to first pixel of first band |
| [in] | width | Number of columns |
| [in] | length | Number of rows |
| [in] | bands | Number of bands |
| [in] | colstride | Stride in bytes between the start of adjacent columns |
| [in] | rowstride | Stride in bytes between the start of adjacent rows |
| [in] | bandstride | Stride in bytes between the start of adjacent bands |
|
inline |
Create a dataset describing an existing in-memory array.
| [in] | data | Pointer to first pixel of first band |
| [in] | width | Number of columns |
| [in] | length | Number of rows |
| [in] | bands | Number of bands |
| [in] | colstride | Stride in bytes between the start of adjacent columns |
| [in] | rowstride | Stride in bytes between the start of adjacent rows |
| [in] | bandstride | Stride in bytes between the start of adjacent bands |
| [in] | access | Access mode |
| GeoTransform isce3::io::gdal::Dataset::getGeoTransform | ( | ) | const |
Get transform from raster coordinates (pixel, line) to projected coordinates (x, y)
If no transform is found, the default (identity) transform is returned.
| isce3::core::ProjectionBase * isce3::io::gdal::Dataset::getProjection | ( | ) | const |
Get spatial reference system.
| isce3::except::GDALError | if the spatial reference system is unavailable |
| Raster isce3::io::gdal::Dataset::getRaster | ( | int | band | ) | const |
Fetch raster band.
| [in] | band | Raster band index (1-based) |
| void isce3::io::gdal::Dataset::setGeoTransform | ( | const GeoTransform & | transform | ) |
Set geotransform.
| isce3::except::GDALError | if the format does not support this operation |
| void isce3::io::gdal::Dataset::setProjection | ( | const isce3::core::ProjectionBase * | proj | ) |
Set spatial reference system.
| isce3::except::GDALError | if the format does not support this operation |
1.13.2.