Skip to content
Permalink
Browse files
Merge pull request #3013 from pierstitus/pseudocolor_renderer
Rewrite pseudocolor render code to improve speed
  • Loading branch information
m-kuhn committed May 9, 2016
2 parents fa11390 + 9470c36 commit 14acde5bb979971f8551b52ec9e306a2ee6e5481
Showing with 163 additions and 238 deletions.
  1. +10 −5 python/core/raster/qgscolorrampshader.sip
  2. +130 −201 src/core/raster/qgscolorrampshader.cpp
  3. +23 −32 src/core/raster/qgscolorrampshader.h
@@ -26,11 +26,12 @@ class QgsColorRampShader : QgsRasterShaderFunction
bool operator<( const QgsColorRampShader::ColorRampItem& other ) const;
};

/** Supported methods for color interpolation. */
enum ColorRamp_TYPE
{
INTERPOLATED,
DISCRETE,
EXACT
INTERPOLATED, //!< Interpolates the color between two class breaks linearly.
DISCRETE, //!< Assigns the color of the higher class for every pixel between two class breaks.
EXACT //!< Assigns the color of the exact matching value in the color ramp item list
};

/** \brief Get the custom colormap*/
@@ -42,7 +43,9 @@ class QgsColorRampShader : QgsRasterShaderFunction
/** \brief Get the color ramp type as a string */
QString colorRampTypeAsQString();

/** \brief Get the maximum size the color cache can be*/
/** \brief Get the maximum size the color cache can be
* @deprecated will be removed in QGIS 3.0. Color cache is not used anymore.
*/
int maximumColorCacheSize();

/** \brief Set custom colormap */
@@ -54,7 +57,9 @@ class QgsColorRampShader : QgsRasterShaderFunction
/** \brief Set the color ramp type*/
void setColorRampType( const QString& theType );

/** \brief Set the maximum size the color cache can be */
/** \brief Set the maximum size the color cache can be
* @deprecated will be removed in QGIS 3.0. Color cache is not used anymore.
*/
void setMaximumColorCacheSize( int theSize );

/** \brief Generates and new RGB value based on one input value */

0 comments on commit 14acde5

Please sign in to comment.