A Raster Transform is a class that defines functions to transform a styled raster. More...
#include <RasterTransform.h>
Public Types | |
| typedef std::map< RasterThreshold, te::color::RGBAColor > | CategorizedMap |
| enum | ContrastType { LINEAR_CONTRAST, SQUARE_CONTRAST, SQUARE_ROOT_CONTRAST, LOG_CONTRAST } |
| typedef std::map< RasterThreshold, te::color::ColorBar > | InterpolatedMap |
| typedef std::pair< double, double > | RasterThreshold |
| enum | RasterTransfFunctions { NO_TRANSF =0, MONO2THREE_TRANSF =1, EXTRACT2RGB_TRANSF =2, RED2THREE_TRANSF =3, GREEN2THREE_TRANSF =4, BLUE2THREE_TRANSF =5, CATEGORIZE_TRANSF =6, INTERPOLATE_TRANSF =7, RECODE_TRANSF = 8, BAND2BAND_TRANSF =9, EXTRACT2RGBA_TRANSF, CONTRAST_TRANSF } |
| typedef std::map< int, te::color::RGBAColor > | RecodedMap |
| typedef te::color::RGBAColor(RasterTransform::* | RGBAFunction) (double, double) |
| enum | RGBChannels { RED_CHANNEL =0, GREEN_CHANNEL =1, BLUE_CHANNEL =2, ALPHA_CHANNEL =3 } |
| The three channels of a display. More... | |
| typedef void(RasterTransform::* | TransformFunction) (double, double, double, double) |
Public Member Functions | |
| void | apply (double icol, double ilin, double ocol, double olin) |
| te::color::RGBAColor | apply (double icol, double ilin) |
| void | clearRGBMap () |
| CategorizedMap & | getCategorizedMap () |
| short | getDestBand () |
| double | getGain () const |
| Gets the gain. More... | |
| double | getGammaB () |
| Gets the constrast value for blue band. More... | |
| double | getGammaG () |
| Gets the constrast value for green band. More... | |
| double | getGammaM () |
| Gets the constrast value for gray band. More... | |
| double | getGammaR () |
| Gets the constrast value for red band. More... | |
| te::rst::Raster * | getInputRaster () |
| Gets the input raster. More... | |
| InterpolatedMap & | getInterpolatedMap () |
| double | getOffset () |
| Gets the offset. More... | |
| te::rst::Raster * | getOutputRaster () |
| Gets the output raster. More... | |
| RecodedMap & | getRecodedMap () |
| std::map< RGBChannels, short > & | getRGBMap () |
| short | getSrcBand () |
| RasterTransfFunctions | getTransfFunction () |
| double | getTransparency () |
| Gets the transparency. More... | |
| RasterTransform (te::rst::Raster *input, te::rst::Raster *output) | |
| Constructor. More... | |
| void | setBChannelMapping (short bIn, RGBChannels bOut) |
| void | setCategorizedMap (CategorizedMap map) |
| void | setContrastGainsAndOffsets (const std::vector< double > &contrastGains, const std::vector< double > &contrastOffsets1, const std::vector< double > &contrastOffsets2) |
| Set gain and offset parameters to be used by the CONTRAST_TRANSF method. More... | |
| void | setContrastType (const ContrastType &newType) |
| Set the current contrast type. More... | |
| void | setDestBand (short n) |
| void | setGain (double value) |
| Sets the gain. More... | |
| void | setGammaB (double value) |
| Sets the constrast value for blue band. More... | |
| void | setGammaG (double value) |
| Sets the constrast value for green band. More... | |
| void | setGammaM (double value) |
| Sets the constrast value for gray band. More... | |
| void | setGammaR (double value) |
| Sets the constrast value for red band. More... | |
| void | setInterpolatedMap (InterpolatedMap map) |
| void | setLinearTransfParameters (double vmin, double vmax, double rmin, double rmax) |
| Set parameters of linear transformation. More... | |
| void | setLinearTransfParameters (double vmin, double vmax, double rmin, double rmax, int band) |
| Set parameters of linear transformation for each band. More... | |
| void | setOffset (double value) |
| Sets the offset 1. More... | |
| void | setRecodedMap (RecodedMap map) |
| void | setRGBAFunction (RasterTransform::RGBAFunction transfFuncPtr) |
| void | setRGBMap (std::map< RGBChannels, short > &rgbMap) |
| Sets the rgb map values. More... | |
| void | setSrcBand (short n) |
| void | setTransfFunction (RasterTransfFunctions func) |
| void | setTransfFunction (RasterTransform::TransformFunction transfFuncPtr) |
| void | setTransparency (double value) |
| Sets the transparency. More... | |
| ~RasterTransform () | |
| Destructor. More... | |
Protected Types | |
| typedef void(RasterTransform::* | ContrastTransformFunction) (const unsigned int &, const double &, double &) const |
| Type definition for the internal contrast transform function. More... | |
Protected Member Functions | |
| void | applyLinearContrast (const unsigned int &bandIdx, const double &inputValue, double &outputValue) const |
| void | applyLogContrast (const unsigned int &bandIdx, const double &inputValue, double &outputValue) const |
| void | applySquareContrast (const unsigned int &bandIdx, const double &inputValue, double &outputValue) const |
| void | applySquareRootContrast (const unsigned int &bandIdx, const double &inputValue, double &outputValue) const |
| double | checkAlphaValue (double icol, double ilin) |
| Function used to check the alpha value. More... | |
| bool | checkNoValue (double &value, int band) const |
| Function used to check if value is or not a valid value. More... | |
| void | fixValue (double &value, short &band) const |
| te::color::RGBAColor | getBlue2ThreeBand (double icol, double ilin) |
| te::color::RGBAColor | getCategorize (double icol, double ilin) |
| te::color::RGBAColor | getCategorizedColor (double value) |
| te::color::RGBAColor | getExtractRGB (double icol, double ilin) |
| te::color::RGBAColor | getExtractRGBA (double icol, double ilin) |
| te::color::RGBAColor | getGreen2ThreeBand (double icol, double ilin) |
| te::color::RGBAColor | getInterpolate (double icol, double ilin) |
| te::color::RGBAColor | getInterpolatedColor (double value) |
| te::color::RGBAColor | getMono2ThreeBand (double icol, double ilin) |
| te::color::RGBAColor | getRecode (double icol, double ilin) |
| te::color::RGBAColor | getRecodedColor (double value) |
| te::color::RGBAColor | getRed2ThreeBand (double icol, double ilin) |
| void | setBand2Band (double icol, double ilin, double ocol, double olin) |
| void | setBlue2ThreeBand (double icol, double ilin, double ocol, double olin) |
| void | setCategorize (double icol, double ilin, double ocol, double olin) |
| void | setContrastFuncPtr (const RasterTransform::ContrastType contrastType) |
| Configures the contrast function pointer. More... | |
| void | setExtractRGB (double icol, double ilin, double ocol, double olin) |
| void | setExtractRGBA (double icol, double ilin, double ocol, double olin) |
| void | setGreen2ThreeBand (double icol, double ilin, double ocol, double olin) |
| void | setInterpolate (double icol, double ilin, double ocol, double olin) |
| void | setMono2ThreeBand (double icol, double ilin, double ocol, double olin) |
| void | setRecode (double icol, double ilin, double ocol, double olin) |
| void | setRed2ThreeBand (double icol, double ilin, double ocol, double olin) |
Private Attributes | |
| CategorizedMap | m_categorizeMap |
| Attribute to define the categorized transformation. More... | |
| std::vector< double > | m_contrastGains |
| A vector of gains for each band used by the CONTRAST method. More... | |
| std::vector< double > | m_contrastOffsets1 |
| A vector of offsets1 for each band used by the CONTRAST method. More... | |
| std::vector< double > | m_contrastOffsets2 |
| A vector of offsets2 for each band used by the CONTRAST method. More... | |
| ContrastTransformFunction | m_contrastTransfFuncPtr |
| Function used in contrast transformation operation. More... | |
| ContrastType | m_currentContrastType |
| Current contrast type. More... | |
| std::vector< double > | m_gamma |
| A vector of gamma gains for each band. More... | |
| InterpolatedMap | m_interpolateMap |
| Attribute to define the interpolated transformation. More... | |
| short | m_monoBand |
| Value for the gray band. More... | |
| short | m_monoBandOut |
| Value for output gray band channel. More... | |
| te::rst::Raster * | m_rasterIn |
| Pointer to a input raster. More... | |
| te::rst::Raster * | m_rasterOut |
| Pointer to a output raster. More... | |
| RecodedMap | m_recodeMap |
| Attribute to define the recoded transformation. More... | |
| RGBAFunction | m_RGBAFuncPtr |
| Function used in transformation operation. More... | |
| std::map< RGBChannels, short > | m_rgbMap |
| Map used to set the band order. More... | |
| std::vector< double > | m_rstMaxValue |
| Max value from input raster. More... | |
| std::vector< double > | m_rstMinValue |
| Min value from input raster. More... | |
| TransformFunction | m_transfFuncPtr |
| Function used in transformation operation. More... | |
| double | m_transp |
| Transparency factor. More... | |
A Raster Transform is a class that defines functions to transform a styled raster.
Definition at line 64 of file RasterTransform.h.
| typedef std::map<RasterThreshold, te::color::RGBAColor> te::map::RasterTransform::CategorizedMap |
Definition at line 73 of file RasterTransform.h.
|
protected |
Type definition for the internal contrast transform function.
Definition at line 279 of file RasterTransform.h.
| typedef std::map<RasterThreshold, te::color::ColorBar> te::map::RasterTransform::InterpolatedMap |
Definition at line 74 of file RasterTransform.h.
| typedef std::pair<double, double> te::map::RasterTransform::RasterThreshold |
Definition at line 71 of file RasterTransform.h.
| typedef std::map<int, te::color::RGBAColor> te::map::RasterTransform::RecodedMap |
Definition at line 75 of file RasterTransform.h.
| typedef te::color::RGBAColor(RasterTransform::* te::map::RasterTransform::RGBAFunction) (double, double) |
Definition at line 69 of file RasterTransform.h.
| typedef void(RasterTransform::* te::map::RasterTransform::TransformFunction) (double, double, double, double) |
Definition at line 68 of file RasterTransform.h.
Definition at line 104 of file RasterTransform.h.
Definition at line 87 of file RasterTransform.h.
The three channels of a display.
| Enumerator | |
|---|---|
| RED_CHANNEL | |
| GREEN_CHANNEL | |
| BLUE_CHANNEL | |
| ALPHA_CHANNEL | |
Definition at line 78 of file RasterTransform.h.
| te::map::RasterTransform::RasterTransform | ( | te::rst::Raster * | input, |
| te::rst::Raster * | output | ||
| ) |
Constructor.
| input | |
| output |
Definition at line 40 of file RasterTransform.cpp.
References te::rst::Raster::getNumberOfBands(), m_contrastGains, m_contrastOffsets1, m_contrastOffsets2, m_gamma, m_rstMaxValue, and m_rstMinValue.
| te::map::RasterTransform::~RasterTransform | ( | ) |
Destructor.
Definition at line 60 of file RasterTransform.cpp.
References m_categorizeMap, m_interpolateMap, m_recodeMap, and m_rgbMap.
|
inline |
Applies the selected transformation method
Definition at line 259 of file RasterTransform.h.
Referenced by te::map::DrawRaster(), te::qt::widgets::ReadPixelTool::mouseReleaseEvent(), and ReadPixelTool::mouseReleaseEvent().
|
inline |
Definition at line 261 of file RasterTransform.h.
|
inlineprotected |
This transformation aplies a linear contrast
Definition at line 345 of file RasterTransform.h.
Referenced by setContrastFuncPtr().
|
inlineprotected |
This transformation aplies a log contrast
Definition at line 367 of file RasterTransform.h.
Referenced by setContrastFuncPtr().
|
inlineprotected |
This transformation aplies a square contrast
Definition at line 353 of file RasterTransform.h.
Referenced by setContrastFuncPtr().
|
inlineprotected |
This transformation aplies a square root contrast
Definition at line 360 of file RasterTransform.h.
Referenced by setContrastFuncPtr().
|
protected |
Function used to check the alpha value.
Definition at line 831 of file RasterTransform.cpp.
References ALPHA_CHANNEL, te::rst::Raster::getValue(), m_rasterIn, m_rgbMap, and m_transp.
Referenced by getBlue2ThreeBand(), getExtractRGB(), getGreen2ThreeBand(), getMono2ThreeBand(), and getRed2ThreeBand().
Function used to check if value is or not a valid value.
Definition at line 385 of file RasterTransform.h.
Referenced by getBlue2ThreeBand(), getCategorize(), getExtractRGB(), getExtractRGBA(), getGreen2ThreeBand(), getInterpolate(), getMono2ThreeBand(), getRecode(), getRed2ThreeBand(), setBand2Band(), setBlue2ThreeBand(), setExtractRGB(), setExtractRGBA(), setGreen2ThreeBand(), setMono2ThreeBand(), and setRed2ThreeBand().
|
inline |
Clears current mapping from bands to channel
Definition at line 188 of file RasterTransform.h.
Referenced by te::map::RasterTransformConfigurer::getChannelSelection().
|
inlineprotected |
Function used to adjust the value in raster range
Definition at line 375 of file RasterTransform.h.
Referenced by getBlue2ThreeBand(), getExtractRGB(), getExtractRGBA(), getGreen2ThreeBand(), getMono2ThreeBand(), getRed2ThreeBand(), setBand2Band(), setBlue2ThreeBand(), setExtractRGB(), setExtractRGBA(), setGreen2ThreeBand(), setMono2ThreeBand(), and setRed2ThreeBand().
|
protected |
This transformation repeats the value of the first band in input three bands of the output
Definition at line 703 of file RasterTransform.cpp.
References BLUE_CHANNEL, checkAlphaValue(), checkNoValue(), fixValue(), te::rst::Raster::getValue(), m_contrastTransfFuncPtr, m_gamma, m_rasterIn, and m_rgbMap.
Referenced by getTransfFunction(), and setTransfFunction().
|
protected |
This transformation get the value of the selected band in input and get the categorized value
Definition at line 742 of file RasterTransform.cpp.
References checkNoValue(), getCategorizedColor(), te::rst::Raster::getValue(), m_monoBand, and m_rasterIn.
Referenced by getTransfFunction(), and setTransfFunction().
|
protected |
Function used to get the categorized color given a pixel value
Definition at line 879 of file RasterTransform.cpp.
References m_categorizeMap.
Referenced by getCategorize(), and setCategorize().
|
inline |
Gets the categorize map information
Definition at line 209 of file RasterTransform.h.
|
inline |
Gets the destination of the mono band
Definition at line 203 of file RasterTransform.h.
|
protected |
This transformation is used to define a particular mapping from input bands to RGB channels
Definition at line 485 of file RasterTransform.cpp.
References BLUE_CHANNEL, checkAlphaValue(), checkNoValue(), fixValue(), te::rst::Raster::getValue(), GREEN_CHANNEL, m_contrastTransfFuncPtr, m_gamma, m_rasterIn, m_rgbMap, and RED_CHANNEL.
Referenced by getTransfFunction(), and setTransfFunction().
|
protected |
This transformation is used to define a particular mapping from input bands to RGBA channels
Definition at line 557 of file RasterTransform.cpp.
References ALPHA_CHANNEL, BLUE_CHANNEL, checkNoValue(), fixValue(), te::rst::Raster::getValue(), GREEN_CHANNEL, m_contrastTransfFuncPtr, m_gamma, m_rasterIn, m_rgbMap, m_transp, and RED_CHANNEL.
Referenced by setTransfFunction().
| double te::map::RasterTransform::getGain | ( | ) | const |
Gets the gain.
Definition at line 73 of file RasterTransform.cpp.
References m_contrastGains.
Referenced by te::map::RasterTransformConfigurer::getGeneralProperties().
| double te::map::RasterTransform::getGammaB | ( | ) |
Gets the constrast value for blue band.
Definition at line 127 of file RasterTransform.cpp.
References BLUE_CHANNEL, and m_gamma.
| double te::map::RasterTransform::getGammaG | ( | ) |
Gets the constrast value for green band.
Definition at line 115 of file RasterTransform.cpp.
References GREEN_CHANNEL, and m_gamma.
| double te::map::RasterTransform::getGammaM | ( | ) |
Gets the constrast value for gray band.
Definition at line 139 of file RasterTransform.cpp.
References m_gamma, and m_monoBand.
| double te::map::RasterTransform::getGammaR | ( | ) |
Gets the constrast value for red band.
Definition at line 103 of file RasterTransform.cpp.
References m_gamma, and RED_CHANNEL.
|
protected |
This transformation repeats the value of the first band in input three bands of the output
Definition at line 659 of file RasterTransform.cpp.
References checkAlphaValue(), checkNoValue(), fixValue(), te::rst::Raster::getValue(), GREEN_CHANNEL, m_contrastTransfFuncPtr, m_gamma, m_rasterIn, and m_rgbMap.
Referenced by getTransfFunction(), and setTransfFunction().
|
inline |
Gets the input raster.
Definition at line 128 of file RasterTransform.h.
Referenced by te::map::RasterTransformConfigurer::getChannelSelection().
|
protected |
This transformation get the value of the selected band in input and get the interpolated value
Definition at line 770 of file RasterTransform.cpp.
References checkNoValue(), getInterpolatedColor(), te::rst::Raster::getValue(), m_monoBand, and m_rasterIn.
Referenced by getTransfFunction(), and setTransfFunction().
|
protected |
Function used to get the interpolated color given a pixel value
Definition at line 849 of file RasterTransform.cpp.
References m_interpolateMap.
Referenced by getInterpolate(), and setInterpolate().
|
inline |
Gets the categorize map information
Definition at line 215 of file RasterTransform.h.
|
protected |
This transformation repeats the value of the first band in input three bands of the output
Definition at line 423 of file RasterTransform.cpp.
References checkAlphaValue(), checkNoValue(), fixValue(), te::rst::Raster::getValue(), m_contrastTransfFuncPtr, m_gamma, m_monoBand, and m_rasterIn.
Referenced by getTransfFunction(), and setTransfFunction().
| double te::map::RasterTransform::getOffset | ( | ) |
Gets the offset.
Definition at line 91 of file RasterTransform.cpp.
References m_contrastOffsets1.
Referenced by te::map::RasterTransformConfigurer::getGeneralProperties().
|
inline |
Gets the output raster.
Definition at line 131 of file RasterTransform.h.
Referenced by te::map::RasterTransformConfigurer::getChannelSelection().
|
protected |
This transformation get the value of the selected band in input and get the recoded value
Definition at line 798 of file RasterTransform.cpp.
References checkNoValue(), getRecodedColor(), te::rst::Raster::getValue(), m_monoBand, and m_rasterIn.
Referenced by getTransfFunction(), and setTransfFunction().
|
protected |
Function used to get the recoded color given a pixel value
Definition at line 898 of file RasterTransform.cpp.
References m_recodeMap.
Referenced by getRecode(), and setRecode().
|
inline |
|
protected |
This transformation repeats the value of the first band in input three bands of the output
Definition at line 615 of file RasterTransform.cpp.
References checkAlphaValue(), checkNoValue(), fixValue(), te::rst::Raster::getValue(), m_contrastTransfFuncPtr, m_gamma, m_rasterIn, m_rgbMap, and RED_CHANNEL.
Referenced by getTransfFunction(), and setTransfFunction().
|
inline |
Returns the mapping from a particular input band to a particular output channel
Definition at line 191 of file RasterTransform.h.
Referenced by te::qt::widgets::ReadPixelTool::mouseReleaseEvent(), and ReadPixelTool::mouseReleaseEvent().
|
inline |
Gets the mono band to be transformed
Definition at line 197 of file RasterTransform.h.
Referenced by te::map::RasterTransformConfigurer::getChannelSelection().
| te::map::RasterTransform::RasterTransfFunctions te::map::RasterTransform::getTransfFunction | ( | ) |
Returns the identifier of the transformation function currently set
Definition at line 238 of file RasterTransform.cpp.
References BAND2BAND_TRANSF, BLUE2THREE_TRANSF, CATEGORIZE_TRANSF, EXTRACT2RGB_TRANSF, getBlue2ThreeBand(), getCategorize(), getExtractRGB(), getGreen2ThreeBand(), getInterpolate(), getMono2ThreeBand(), getRecode(), getRed2ThreeBand(), GREEN2THREE_TRANSF, INTERPOLATE_TRANSF, m_RGBAFuncPtr, m_transfFuncPtr, MONO2THREE_TRANSF, NO_TRANSF, RECODE_TRANSF, RED2THREE_TRANSF, setBand2Band(), setBlue2ThreeBand(), setCategorize(), setExtractRGB(), setGreen2ThreeBand(), setInterpolate(), setMono2ThreeBand(), setRecode(), and setRed2ThreeBand().
|
inline |
Gets the transparency.
Definition at line 137 of file RasterTransform.h.
|
protected |
This transformation repeats the value of the n band in input to b band in output
Definition at line 810 of file RasterTransform.cpp.
References band, checkNoValue(), fixValue(), te::rst::Raster::getNumberOfBands(), te::rst::Raster::getValue(), m_contrastTransfFuncPtr, m_gamma, m_rasterIn, m_rasterOut, and te::rst::Raster::setValue().
Referenced by getTransfFunction(), and setTransfFunction().
|
inline |
Sets the mapping from a particular input band to a particular output channel
Definition at line 185 of file RasterTransform.h.
Referenced by te::map::RasterTransformConfigurer::getBlueChannelProperties(), te::map::RasterTransformConfigurer::getChannelSelection(), te::map::RasterTransformConfigurer::getGreenChannelProperties(), and te::map::RasterTransformConfigurer::getRedChannelProperties().
|
protected |
This transformation repeats the value of the first band in input three bands of the output
Definition at line 682 of file RasterTransform.cpp.
References BLUE_CHANNEL, checkNoValue(), fixValue(), te::rst::Raster::getValue(), m_contrastTransfFuncPtr, m_gamma, m_rasterIn, m_rasterOut, m_rgbMap, and te::rst::Raster::setValues().
Referenced by getTransfFunction(), and setTransfFunction().
|
protected |
This transformation get the value of the selected band in input and set the categorized value in output bands of the output
Definition at line 726 of file RasterTransform.cpp.
References te::color::RGBAColor::getBlue(), getCategorizedColor(), te::color::RGBAColor::getGreen(), te::color::RGBAColor::getRed(), te::rst::Raster::getValue(), m_monoBand, m_rasterIn, m_rasterOut, and te::rst::Raster::setValues().
Referenced by getTransfFunction(), and setTransfFunction().
|
inline |
Sets the categorize map information
Definition at line 206 of file RasterTransform.h.
Referenced by te::map::RasterTransformConfigurer::getCategorizedMap().
|
protected |
Configures the contrast function pointer.
| contrastType | Contrast type.. |
Definition at line 374 of file RasterTransform.cpp.
References applyLinearContrast(), applyLogContrast(), applySquareContrast(), applySquareRootContrast(), LINEAR_CONTRAST, LOG_CONTRAST, m_contrastTransfFuncPtr, SQUARE_CONTRAST, and SQUARE_ROOT_CONTRAST.
Referenced by setContrastType().
| void te::map::RasterTransform::setContrastGainsAndOffsets | ( | const std::vector< double > & | contrastGains, |
| const std::vector< double > & | contrastOffsets1, | ||
| const std::vector< double > & | contrastOffsets2 | ||
| ) |
Set gain and offset parameters to be used by the CONTRAST_TRANSF method.
| contrastGains | A vector of gains for each raster band. |
| contrastOffsets1 | A vector of offsets1 for each raster band. |
| contrastOffsets2 | A vector of offsets2 for each raster band. |
Definition at line 353 of file RasterTransform.cpp.
References te::rst::Raster::getNumberOfBands(), m_contrastGains, m_contrastOffsets1, m_contrastOffsets2, m_rasterIn, and TE_TR.
Referenced by te::map::DrawRaster().
| void te::map::RasterTransform::setContrastType | ( | const ContrastType & | newType | ) |
Set the current contrast type.
| newType | New contrast type. |
Definition at line 85 of file RasterTransform.cpp.
References m_currentContrastType, and setContrastFuncPtr().
Referenced by te::map::DrawRaster().
|
inline |
Sets the destination of the mono band
Definition at line 200 of file RasterTransform.h.
|
protected |
This transformation is used to define a particular mapping from input bands to RGB channels
Definition at line 452 of file RasterTransform.cpp.
References BLUE_CHANNEL, checkNoValue(), fixValue(), te::rst::Raster::getValue(), GREEN_CHANNEL, m_contrastTransfFuncPtr, m_gamma, m_rasterIn, m_rasterOut, m_rgbMap, RED_CHANNEL, and te::rst::Raster::setValues().
Referenced by getTransfFunction(), and setTransfFunction().
|
protected |
This transformation is used to define a particular mapping from input bands to RGBA channels
Definition at line 519 of file RasterTransform.cpp.
References ALPHA_CHANNEL, BLUE_CHANNEL, checkNoValue(), fixValue(), te::rst::Raster::getValue(), GREEN_CHANNEL, m_contrastTransfFuncPtr, m_gamma, m_rasterIn, m_rasterOut, m_rgbMap, RED_CHANNEL, and te::rst::Raster::setValues().
Referenced by setTransfFunction().
| void te::map::RasterTransform::setGain | ( | double | value | ) |
Sets the gain.
Definition at line 68 of file RasterTransform.cpp.
References m_contrastGains.
Referenced by te::map::RasterTransformConfigurer::getGeneralProperties().
| void te::map::RasterTransform::setGammaB | ( | double | value | ) |
Sets the constrast value for blue band.
Definition at line 121 of file RasterTransform.cpp.
References BLUE_CHANNEL, and m_gamma.
Referenced by te::map::RasterTransformConfigurer::getBlueChannelProperties().
| void te::map::RasterTransform::setGammaG | ( | double | value | ) |
Sets the constrast value for green band.
Definition at line 109 of file RasterTransform.cpp.
References GREEN_CHANNEL, and m_gamma.
Referenced by te::map::RasterTransformConfigurer::getGreenChannelProperties().
| void te::map::RasterTransform::setGammaM | ( | double | value | ) |
Sets the constrast value for gray band.
Definition at line 133 of file RasterTransform.cpp.
References m_gamma, and m_monoBand.
Referenced by te::map::RasterTransformConfigurer::getGrayChannelProperties().
| void te::map::RasterTransform::setGammaR | ( | double | value | ) |
Sets the constrast value for red band.
Definition at line 97 of file RasterTransform.cpp.
References m_gamma, and RED_CHANNEL.
Referenced by te::map::RasterTransformConfigurer::getRedChannelProperties().
|
protected |
This transformation repeats the value of the first band in input three bands of the output
Definition at line 638 of file RasterTransform.cpp.
References checkNoValue(), fixValue(), te::rst::Raster::getValue(), GREEN_CHANNEL, m_contrastTransfFuncPtr, m_gamma, m_rasterIn, m_rasterOut, m_rgbMap, and te::rst::Raster::setValues().
Referenced by getTransfFunction(), and setTransfFunction().
|
protected |
This transformation get the value of the selected band in input and set the interpolated value in output bands of the output
Definition at line 754 of file RasterTransform.cpp.
References te::color::RGBAColor::getBlue(), te::color::RGBAColor::getGreen(), getInterpolatedColor(), te::color::RGBAColor::getRed(), te::rst::Raster::getValue(), m_monoBand, m_rasterIn, m_rasterOut, and te::rst::Raster::setValues().
Referenced by getTransfFunction(), and setTransfFunction().
|
inline |
Sets the interpolate map information
Definition at line 212 of file RasterTransform.h.
Referenced by te::map::RasterTransformConfigurer::getInterpolatedMap().
| void te::map::RasterTransform::setLinearTransfParameters | ( | double | vmin, |
| double | vmax, | ||
| double | rmin, | ||
| double | rmax | ||
| ) |
Set parameters of linear transformation.
| vmin | smallest input value |
| vmax | largest input value |
| rmin | smallest value of the output range |
| rmax | largest value of the output range |
Definition at line 172 of file RasterTransform.cpp.
References m_contrastGains, m_contrastOffsets1, m_contrastOffsets2, m_rstMaxValue, and m_rstMinValue.
Referenced by te::map::DrawRaster(), te::qt::widgets::ReadPixelTool::mouseReleaseEvent(), and ReadPixelTool::mouseReleaseEvent().
| void te::map::RasterTransform::setLinearTransfParameters | ( | double | vmin, |
| double | vmax, | ||
| double | rmin, | ||
| double | rmax, | ||
| int | band | ||
| ) |
Set parameters of linear transformation for each band.
| vmin | smallest input value |
| vmax | largest input value |
| rmin | smallest value of the output range |
| rmax | largest value of the output range |
| band | band id |
Definition at line 205 of file RasterTransform.cpp.
References band, m_contrastGains, m_contrastOffsets1, m_contrastOffsets2, m_rstMaxValue, and m_rstMinValue.
|
protected |
This transformation repeats the value of the first band in input three bands of the output
Definition at line 402 of file RasterTransform.cpp.
References checkNoValue(), fixValue(), te::rst::Raster::getValue(), m_contrastTransfFuncPtr, m_gamma, m_monoBand, m_rasterIn, m_rasterOut, and te::rst::Raster::setValues().
Referenced by getTransfFunction(), and setTransfFunction().
| void te::map::RasterTransform::setOffset | ( | double | value | ) |
Sets the offset 1.
Definition at line 79 of file RasterTransform.cpp.
References m_contrastOffsets1, and m_contrastOffsets2.
Referenced by te::map::RasterTransformConfigurer::getGeneralProperties().
|
protected |
This transformation get the value of the selected band in input and set the recoded value in output bands of the output
Definition at line 782 of file RasterTransform.cpp.
References te::color::RGBAColor::getBlue(), te::color::RGBAColor::getGreen(), getRecodedColor(), te::color::RGBAColor::getRed(), te::rst::Raster::getValue(), m_monoBand, m_rasterIn, m_rasterOut, and te::rst::Raster::setValues().
Referenced by getTransfFunction(), and setTransfFunction().
|
inline |
Sets the recode map information
Definition at line 218 of file RasterTransform.h.
Referenced by te::map::RasterTransformConfigurer::getChannelSelection(), and te::map::RasterTransformConfigurer::getRecodedMap().
|
protected |
This transformation repeats the value of the first band in input three bands of the output
Definition at line 594 of file RasterTransform.cpp.
References checkNoValue(), fixValue(), te::rst::Raster::getValue(), m_contrastTransfFuncPtr, m_gamma, m_rasterIn, m_rasterOut, m_rgbMap, RED_CHANNEL, and te::rst::Raster::setValues().
Referenced by getTransfFunction(), and setTransfFunction().
|
inline |
Sets the transformation method to be used
Definition at line 256 of file RasterTransform.h.
| void te::map::RasterTransform::setRGBMap | ( | std::map< RGBChannels, short > & | rgbMap | ) |
Sets the rgb map values.
Definition at line 145 of file RasterTransform.cpp.
References ALPHA_CHANNEL, BLUE_CHANNEL, GREEN_CHANNEL, m_rgbMap, and RED_CHANNEL.
|
inline |
Sets the mono band to be transformed
Definition at line 194 of file RasterTransform.h.
Referenced by te::map::RasterTransformConfigurer::getGrayChannelProperties().
| void te::map::RasterTransform::setTransfFunction | ( | RasterTransfFunctions | func | ) |
Sets the associated transformation function from an identifier
Definition at line 294 of file RasterTransform.cpp.
References BAND2BAND_TRANSF, BLUE2THREE_TRANSF, CATEGORIZE_TRANSF, EXTRACT2RGB_TRANSF, EXTRACT2RGBA_TRANSF, getBlue2ThreeBand(), getCategorize(), getExtractRGB(), getExtractRGBA(), getGreen2ThreeBand(), getInterpolate(), getMono2ThreeBand(), getRecode(), getRed2ThreeBand(), GREEN2THREE_TRANSF, INTERPOLATE_TRANSF, m_RGBAFuncPtr, m_transfFuncPtr, MONO2THREE_TRANSF, RECODE_TRANSF, RED2THREE_TRANSF, setBand2Band(), setBlue2ThreeBand(), setCategorize(), setExtractRGB(), setExtractRGBA(), setGreen2ThreeBand(), setInterpolate(), setMono2ThreeBand(), setRecode(), and setRed2ThreeBand().
Referenced by te::map::RasterTransformConfigurer::getChannelSelection(), and te::map::RasterTransformConfigurer::getColorMapInformation().
|
inline |
Sets the transformation method to be used
Definition at line 253 of file RasterTransform.h.
|
inline |
Sets the transparency.
Definition at line 134 of file RasterTransform.h.
Referenced by te::map::RasterTransformConfigurer::getGeneralProperties().
|
private |
Attribute to define the categorized transformation.
Definition at line 425 of file RasterTransform.h.
Referenced by getCategorizedColor(), and ~RasterTransform().
|
private |
A vector of gains for each band used by the CONTRAST method.
Definition at line 430 of file RasterTransform.h.
Referenced by getGain(), RasterTransform(), setContrastGainsAndOffsets(), setGain(), and setLinearTransfParameters().
|
private |
A vector of offsets1 for each band used by the CONTRAST method.
Definition at line 431 of file RasterTransform.h.
Referenced by getOffset(), RasterTransform(), setContrastGainsAndOffsets(), setLinearTransfParameters(), and setOffset().
|
private |
A vector of offsets2 for each band used by the CONTRAST method.
Definition at line 432 of file RasterTransform.h.
Referenced by RasterTransform(), setContrastGainsAndOffsets(), setLinearTransfParameters(), and setOffset().
|
private |
Function used in contrast transformation operation.
Definition at line 412 of file RasterTransform.h.
Referenced by getBlue2ThreeBand(), getExtractRGB(), getExtractRGBA(), getGreen2ThreeBand(), getMono2ThreeBand(), getRed2ThreeBand(), setBand2Band(), setBlue2ThreeBand(), setContrastFuncPtr(), setExtractRGB(), setExtractRGBA(), setGreen2ThreeBand(), setMono2ThreeBand(), and setRed2ThreeBand().
|
private |
Current contrast type.
Definition at line 411 of file RasterTransform.h.
Referenced by setContrastType().
|
private |
A vector of gamma gains for each band.
Definition at line 429 of file RasterTransform.h.
Referenced by getBlue2ThreeBand(), getExtractRGB(), getExtractRGBA(), getGammaB(), getGammaG(), getGammaM(), getGammaR(), getGreen2ThreeBand(), getMono2ThreeBand(), getRed2ThreeBand(), RasterTransform(), setBand2Band(), setBlue2ThreeBand(), setExtractRGB(), setExtractRGBA(), setGammaB(), setGammaG(), setGammaM(), setGammaR(), setGreen2ThreeBand(), setMono2ThreeBand(), and setRed2ThreeBand().
|
private |
Attribute to define the interpolated transformation.
Definition at line 426 of file RasterTransform.h.
Referenced by getInterpolatedColor(), and ~RasterTransform().
|
private |
Value for the gray band.
Definition at line 419 of file RasterTransform.h.
Referenced by getCategorize(), getGammaM(), getInterpolate(), getMono2ThreeBand(), getRecode(), setCategorize(), setGammaM(), setInterpolate(), setMono2ThreeBand(), and setRecode().
|
private |
Value for output gray band channel.
Definition at line 420 of file RasterTransform.h.
|
private |
Pointer to a input raster.
Definition at line 408 of file RasterTransform.h.
Referenced by checkAlphaValue(), getBlue2ThreeBand(), getCategorize(), getExtractRGB(), getExtractRGBA(), getGreen2ThreeBand(), getInterpolate(), getMono2ThreeBand(), getRecode(), getRed2ThreeBand(), setBand2Band(), setBlue2ThreeBand(), setCategorize(), setContrastGainsAndOffsets(), setExtractRGB(), setExtractRGBA(), setGreen2ThreeBand(), setInterpolate(), setMono2ThreeBand(), setRecode(), and setRed2ThreeBand().
|
private |
Pointer to a output raster.
Definition at line 409 of file RasterTransform.h.
Referenced by setBand2Band(), setBlue2ThreeBand(), setCategorize(), setExtractRGB(), setExtractRGBA(), setGreen2ThreeBand(), setInterpolate(), setMono2ThreeBand(), setRecode(), and setRed2ThreeBand().
|
private |
Attribute to define the recoded transformation.
Definition at line 427 of file RasterTransform.h.
Referenced by getRecodedColor(), and ~RasterTransform().
|
private |
Function used in transformation operation.
Definition at line 423 of file RasterTransform.h.
Referenced by getTransfFunction(), and setTransfFunction().
|
private |
Map used to set the band order.
Definition at line 418 of file RasterTransform.h.
Referenced by checkAlphaValue(), getBlue2ThreeBand(), getExtractRGB(), getExtractRGBA(), getGreen2ThreeBand(), getRed2ThreeBand(), setBlue2ThreeBand(), setExtractRGB(), setExtractRGBA(), setGreen2ThreeBand(), setRed2ThreeBand(), setRGBMap(), and ~RasterTransform().
|
private |
Max value from input raster.
Definition at line 416 of file RasterTransform.h.
Referenced by RasterTransform(), and setLinearTransfParameters().
|
private |
Min value from input raster.
Definition at line 415 of file RasterTransform.h.
Referenced by RasterTransform(), and setLinearTransfParameters().
|
private |
Function used in transformation operation.
Definition at line 422 of file RasterTransform.h.
Referenced by getTransfFunction(), and setTransfFunction().
|
private |
Transparency factor.
Definition at line 414 of file RasterTransform.h.
Referenced by checkAlphaValue(), and getExtractRGBA().