15#ifndef QGSRASTERFILEWRITER_H
16#define QGSRASTERFILEWRITER_H
21#include <QDomDocument>
49 SortRecommended = 1 << 1,
66 int width,
int height,
78 int width,
int height,
116 QString outputUrl()
const {
return mOutputUrl; }
307 static QString filterForDriver(
const QString &driverName );
330 static QList< QgsRasterFileWriter::FilterFormatDetails > supportedFiltersAndFormats(
RasterFormatOptions options = SortRecommended );
340 static QStringList supportedFormatExtensions(
RasterFormatOptions options = SortRecommended );
351 static QString driverForExtension(
const QString &extension );
363 static QStringList extensionsForFormat(
const QString &format );
374 int nCols,
int nRows,
378 const QList<bool> &destHasNoDataValueList,
379 const QList<double> &destNoDataValueList,
399 bool writeVRT(
const QString &file );
401 void addToVRT(
const QString &filename,
int band,
int xSize,
int ySize,
int xOffset,
int yOffset );
406 int iterLeft,
int iterTop,
407 const QString &outputUrl,
int fileIndex,
int nBands,
Qgis::DataType type,
424 const QList<bool> &destHasNoDataValueList = QList<bool>(),
const QList<double> &destNoDataValueList = QList<double>() );
427 void globalOutputParameters(
const QgsRectangle &extent,
int nCols,
int &nRows,
double *geoTransform,
double &pixelSize );
429 QString partFileName(
int fileIndex );
430 QString vrtFileName();
434 QString mOutputProviderKey = QStringLiteral(
"gdal" );
435 QString mOutputFormat = QStringLiteral(
"GTiff" );
436 QStringList mCreationOptions;
440 bool mTiledMode =
false;
441 int mMaxTileWidth = 500;
442 int mMaxTileHeight = 500;
444 QList< int > mPyramidsList;
445 QString mPyramidsResampling = QStringLiteral(
"AVERAGE" );
448 QStringList mPyramidsConfigOptions;
450 QDomDocument mVRTDocument;
451 QList<QDomElement> mVRTBands;
Provides global constants and enumerations for use throughout the application.
RasterPyramidFormat
Raster pyramid formats.
@ GeoTiff
Geotiff .ovr (external)
RasterFileWriterResult
Raster file export results.
DataType
Raster data types.
RasterBuildPyramidOption
Raster pyramid building options.
RasterExportType
Raster file export types.
Represents a coordinate reference system (CRS).
Contains information about the context in which a coordinate transform is executed.
Feedback object tailored for raster block reading.
Base class for raster data providers.
The raster file writer which allows you to save a raster to a new file.
void setPyramidsList(const QList< int > &list)
Sets the list of pyramids which will be created for the output file.
enum RasterFormatOption SIP_ENUM_BASETYPE(IntFlag)
Options for sorting and filtering raster formats.
void setPyramidsResampling(const QString &str)
int maxTileHeight() const
Returns the maximum tile height (in pixels) for tiled outputs.
void setMaxTileWidth(int w)
Sets the maximum tile width (in pixels) for tiled outputs.
void setTiledMode(bool t)
Sets whether the output should be tiled.
QStringList pyramidsConfigOptions() const
Returns the list of configuration options used when creating the pyramids for the output raster file.
Q_DECL_DEPRECATED QStringList createOptions() const SIP_DEPRECATED
Returns the list of data source creation options which will be used when creating the output raster f...
Qgis::RasterBuildPyramidOption buildPyramidsFlag() const
Returns the pyramid building option.
void setOutputProviderKey(const QString &key)
Sets the name of the data provider for the raster output.
void setMaxTileHeight(int h)
Sets the maximum tile height (in pixels) for tiled outputs.
QFlags< RasterFormatOption > RasterFormatOptions
Qgis::RasterPyramidFormat pyramidsFormat() const
Returns the raster pyramid format.
QString outputFormat() const
Returns the output format.
QString outputProviderKey() const
Returns the name of the data provider for the raster output.
QString pyramidsResampling() const
void setCreationOptions(const QStringList &options)
Sets a list of data source creation options to use when creating the output raster file.
QList< int > pyramidsList() const
Returns the list of pyramids which will be created for the output file.
void setPyramidsFormat(Qgis::RasterPyramidFormat f)
Sets the raster pyramid format.
QStringList creationOptions() const
Returns the list of data source creation options which will be used when creating the output raster f...
void setOutputFormat(const QString &format)
Sets the output format.
int maxTileWidth() const
Returns the maximum tile width (in pixels) for tiled outputs.
Q_DECL_DEPRECATED void setCreateOptions(const QStringList &list) SIP_DEPRECATED
Sets a list of data source creation options to use when creating the output raster file.
bool tiledMode() const
Returns whether the output will be tiled.
void setPyramidsConfigOptions(const QStringList &list)
Sets a list of configuration options to use when creating the pyramids for the output raster file.
void setBuildPyramidsFlag(Qgis::RasterBuildPyramidOption f)
Sets the pyramid building option.
Base class for processing filters like renderers, reprojector, resampler etc.
Iterator for sequentially processing raster cells.
Contains a pipeline of raster interfaces for sequential raster processing.
A rectangle specified with double values.
const QgsCoordinateReferenceSystem & crs