Skip to content
Permalink
Browse files

betetr use qgsDoubleNear

  • Loading branch information
luipir committed Feb 1, 2019
1 parent 78d9488 commit a9fcfe9a5570a6f1462f39321770bb09f8fe8db3
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/core/raster/qgssinglebandgrayrenderer.cpp
@@ -283,7 +283,7 @@ void QgsSingleBandGrayRenderer::toSld( QDomDocument &doc, QDomElement &element,
QgsRasterBandStats myRasterBandStats = mInput->bandStatistics( grayBand(), QgsRasterBandStats::Min | QgsRasterBandStats::Max );

// if minimum range differ from the real minimum => set is in exported SLD vendor option
if ( contrastEnhancement()->minimumValue() != myRasterBandStats.minimumValue )
if ( !qgsDoubleNear( contrastEnhancement()->minimumValue(), myRasterBandStats.minimumValue ) )
{
// look for VendorOption tag to look for that with minValue attribute
QDomNodeList elements = contrastEnhancementElem.elementsByTagName( QStringLiteral( "sld:VendorOption" ) );

0 comments on commit a9fcfe9

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