QGIS API Documentation 3.41.0-Master (af5edcb665c)
|
Utility class for gathering information about rasters. More...
#include <qgsalignraster.h>
Public Member Functions | |
RasterInfo (const QString &layerpath) | |
Construct raster info with a path to a raster file. | |
RasterInfo (const RasterInfo &rh)=delete | |
int | bandCount () const |
Returns the number of raster bands in the file. | |
QSizeF | cellSize () const |
Returns the cell size in map units. | |
QString | crs () const |
Returns the CRS in WKT format. | |
void | dump () const |
Write contents of the object to standard error stream - for debugging. | |
QgsRectangle | extent () const |
Returns the extent of the raster. | |
QPointF | gridOffset () const |
Returns the grid offset. | |
double | identify (double mx, double my) |
Gets raster value at the given coordinates (from the first band) | |
bool | isValid () const |
Check whether the given path is a valid raster. | |
RasterInfo & | operator= (const RasterInfo &rh)=delete |
QPointF | origin () const |
Returns the origin of the raster. | |
QSize | rasterSize () const |
Returns the size of the raster grid in pixels. | |
Protected Attributes | |
int | mBandCnt = 0 |
number of raster's bands | |
QString | mCrsWkt |
CRS stored in WKT format. | |
gdal::dataset_unique_ptr | mDataset |
handle to open GDAL dataset | |
double | mGeoTransform [6] |
geotransform coefficients | |
int | mXSize = 0 |
raster grid size X | |
int | mYSize = 0 |
raster grid size Y | |
Friends | |
class | QgsAlignRaster |
Utility class for gathering information about rasters.
Definition at line 53 of file qgsalignraster.h.
QgsAlignRaster::RasterInfo::RasterInfo | ( | const QString & | layerpath | ) |
Construct raster info with a path to a raster file.
Definition at line 540 of file qgsalignraster.cpp.
|
delete |
|
inline |
Returns the number of raster bands in the file.
Definition at line 70 of file qgsalignraster.h.
QSizeF QgsAlignRaster::RasterInfo::cellSize | ( | ) | const |
Returns the cell size in map units.
Definition at line 557 of file qgsalignraster.cpp.
|
inline |
Returns the CRS in WKT format.
Definition at line 66 of file qgsalignraster.h.
void QgsAlignRaster::RasterInfo::dump | ( | ) | const |
Write contents of the object to standard error stream - for debugging.
Definition at line 577 of file qgsalignraster.cpp.
QgsRectangle QgsAlignRaster::RasterInfo::extent | ( | ) | const |
Returns the extent of the raster.
Definition at line 567 of file qgsalignraster.cpp.
QPointF QgsAlignRaster::RasterInfo::gridOffset | ( | ) | const |
Returns the grid offset.
Definition at line 562 of file qgsalignraster.cpp.
double QgsAlignRaster::RasterInfo::identify | ( | double | mx, |
double | my | ||
) |
Gets raster value at the given coordinates (from the first band)
Definition at line 592 of file qgsalignraster.cpp.
|
inline |
Check whether the given path is a valid raster.
Definition at line 63 of file qgsalignraster.h.
|
delete |
QPointF QgsAlignRaster::RasterInfo::origin | ( | ) | const |
Returns the origin of the raster.
Definition at line 572 of file qgsalignraster.cpp.
|
inline |
Returns the size of the raster grid in pixels.
Definition at line 68 of file qgsalignraster.h.
|
friend |
Definition at line 105 of file qgsalignraster.h.
|
protected |
number of raster's bands
Definition at line 98 of file qgsalignraster.h.
|
protected |
CRS stored in WKT format.
Definition at line 90 of file qgsalignraster.h.
|
protected |
handle to open GDAL dataset
Definition at line 88 of file qgsalignraster.h.
|
protected |
geotransform coefficients
Definition at line 92 of file qgsalignraster.h.
|
protected |
raster grid size X
Definition at line 94 of file qgsalignraster.h.
|
protected |
raster grid size Y
Definition at line 96 of file qgsalignraster.h.