Skip to content
Permalink
Browse files

Fix sign of safety correction

  • Loading branch information
pierstitus committed Apr 27, 2016
1 parent 208a14e commit 593296949c34bf73c63a9a505d50155daddf8258
Showing with 2 additions and 2 deletions.
  1. +1 −1 src/core/raster/qgscolorrampshader.cpp
  2. +1 −1 src/core/raster/qgscolorrampshader.h
@@ -100,7 +100,7 @@ bool QgsColorRampShader::shade( double theValue, int* theReturnRedValue, int* th
if ( rangeValue > 0 )
{
int lutSize = 256; // TODO: test if speed can be increased with a different LUT size
mLUTFactor = ( lutSize + 0.0000001 ) / rangeValue; // increase slightly to make sure last LUT category is correct
mLUTFactor = ( lutSize - 0.0000001 ) / rangeValue; // decrease slightly to make sure last LUT category is correct
idx = 0;
double val;
mLUT.reserve( lutSize );
@@ -130,7 +130,7 @@ class CORE_EXPORT QgsColorRampShader : public QgsRasterShaderFunction
/** Maximum size of the color cache. The color cache could eat a ton of
* memory if you have 32-bit data
* @deprecated will be removed in QGIS 3.0 */
Q_DECL_DEPRECATED int mMaximumColorCacheSize;
int mMaximumColorCacheSize;

/** Do not render values out of range */
bool mClip;

0 comments on commit 5932969

Please sign in to comment.
You can’t perform that action at this time.