OGS
|
The VtkVisPipeline source object of a geo-referenced image (file).
Definition at line 39 of file VtkGeoImageSource.h.
#include <VtkGeoImageSource.h>
Public Member Functions | |
vtkTypeMacro (VtkGeoImageSource, vtkSimpleImageToImageFilter) | |
void | PrintSelf (ostream &os, vtkIndent indent) override |
Prints information about itself. | |
VtkGeoImageSource (const VtkGeoImageSource &)=delete | |
void | operator= (const VtkGeoImageSource &)=delete |
vtkImageData * | getImageData () |
Returns the ImageData object. | |
bool | readImage (const QString &filename) |
Reads an image from file. | |
void | setImage (vtkImageAlgorithm *image, const QString &name) |
Imports an existing image object. | |
void | SetUserProperty (QString name, QVariant value) override |
Sets a user property. This should be implemented by subclasses. | |
Public Member Functions inherited from VtkAlgorithmProperties | |
VtkAlgorithmProperties (QObject *parent=nullptr) | |
Constructor (sets default values) | |
~VtkAlgorithmProperties () override | |
vtkProperty * | GetProperties () const |
Returns the vtk properties. | |
vtkTexture * | GetTexture () |
Returns a texture (if one has been assigned). | |
void | SetTexture (vtkTexture *t) |
Sets a texture for the VtkVisPipelineItem. | |
vtkLookupTable * | GetLookupTable (const QString &array_name) |
Returns the colour lookup table (if one has been assigned). | |
void | RemoveLookupTable (const QString &array_name) |
Removes the lookup table for the given scalar. | |
void | SetLookUpTable (const QString &array_name, vtkLookupTable *lut) |
Sets a colour lookup table for the given scalar array of the VtkVisPipelineItem. | |
void | SetLookUpTable (const QString &array_name, const QString &filename) |
Loads a predefined color lookup table from a file for the specified scalar array. | |
bool | GetScalarVisibility () const |
Returns the scalar visibility. | |
void | SetScalarVisibility (bool on) |
Sets the scalar visibility. | |
QString | GetName () const |
Returns the name. This is set to the file path if it is a source algorithm. | |
void | SetName (QString name) |
Sets the name. | |
bool | IsRemovable () const |
Is this algorithm removable from the pipeline (view). | |
QMap< QString, QVariant > * | GetAlgorithmUserProperties () const |
Returns a map of user properties. | |
QMap< QString, QList< QVariant > > * | GetAlgorithmUserVectorProperties () const |
Returns a map of vector user properties. | |
QVariant | GetUserProperty (QString name) const |
Returns the value of a user property. | |
virtual void | SetUserVectorProperty (QString name, QList< QVariant > values) |
Sets a vector user property. This should be implemented by subclasses. | |
QList< QVariant > | GetUserVectorProperty (QString name) const |
Returns a list of values of a vector user property. | |
void | SetActiveAttribute (QString name) |
Set the active attribute. | |
QString | GetActiveAttribute () const |
Returns the desired active attribute. | |
Static Public Member Functions | |
static VtkGeoImageSource * | New () |
Create new objects with New() because of VTKs reference counting. | |
static std::optional< GeoLib::Raster > | convertToRaster (VtkGeoImageSource *const source) |
Protected Member Functions | |
VtkGeoImageSource () | |
Constructor. | |
~VtkGeoImageSource () override | |
Destructor. | |
void | SimpleExecute (vtkImageData *input, vtkImageData *output) override |
Filter execution. | |
Private Attributes | |
vtkImageAlgorithm * | _imageSource {nullptr} |
Additional Inherited Members | |
Signals inherited from VtkAlgorithmProperties | |
void | ScalarVisibilityChanged (bool on) |
Protected Attributes inherited from VtkAlgorithmProperties | |
vtkProperty * | _property |
vtkTexture * | _texture |
bool | _scalarVisibility |
std::map< QString, vtkLookupTable * > | _lut |
QString | _name |
QString | _activeAttributeName |
bool | _removable |
QMap< QString, QVariant > * | _algorithmUserProperties |
QMap< QString, QList< QVariant > > * | _algorithmUserVectorProperties |
|
delete |
|
protecteddefault |
Constructor.
|
overrideprotected |
Destructor.
Definition at line 63 of file VtkGeoImageSource.cpp.
References _imageSource.
|
static |
Definition at line 122 of file VtkGeoImageSource.cpp.
References ERR().
Referenced by VtkVisPipelineView::showImageToMeshConversionDialog(), and VtkVisImageItem::writeAsRaster().
vtkImageData * VtkGeoImageSource::getImageData | ( | ) |
Returns the ImageData object.
Definition at line 94 of file VtkGeoImageSource.cpp.
References _imageSource.
|
static |
Create new objects with New() because of VTKs reference counting.
Referenced by NetCdfConfigureDialog::createDataObject(), and MainWindow::loadFile().
|
delete |
|
override |
Prints information about itself.
Definition at line 71 of file VtkGeoImageSource.cpp.
bool VtkGeoImageSource::readImage | ( | const QString & | filename | ) |
Reads an image from file.
Definition at line 76 of file VtkGeoImageSource.cpp.
References VtkRaster::loadImage(), and setImage().
Referenced by MainWindow::loadFile().
void VtkGeoImageSource::setImage | ( | vtkImageAlgorithm * | image, |
const QString & | name ) |
Imports an existing image object.
Definition at line 87 of file VtkGeoImageSource.cpp.
References _imageSource, and VtkAlgorithmProperties::SetName().
Referenced by NetCdfConfigureDialog::createDataObject(), and readImage().
|
overridevirtual |
Sets a user property. This should be implemented by subclasses.
Reimplemented from VtkAlgorithmProperties.
Definition at line 116 of file VtkGeoImageSource.cpp.
|
overrideprotected |
Filter execution.
Definition at line 99 of file VtkGeoImageSource.cpp.
References vtkSimpleImageFilterExampleExecute().
VtkGeoImageSource::vtkTypeMacro | ( | VtkGeoImageSource | , |
vtkSimpleImageToImageFilter | ) |
|
private |
Definition at line 79 of file VtkGeoImageSource.h.
Referenced by ~VtkGeoImageSource(), getImageData(), and setImage().