mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-25 00:58:06 -05:00
Added missing support for inverting histogram on non-pseudocolor grayscale layers.
git-svn-id: http://svn.osgeo.org/qgis/trunk@408 c8812cc2-4d05-0410-92ff-de0c093fc19c
This commit is contained in:
parent
c9839c235b
commit
f498bab6b9
@ -271,6 +271,7 @@ void QgsRasterLayer::draw(QPainter * theQPainter, QgsRect * theViewExtent, QgsCo
|
||||
{
|
||||
myGrayValInt = static_cast<int>((255/myRangeDouble) * myGrayValInt);
|
||||
}
|
||||
if (invertHistogramFlag) myGrayValInt=255-myGrayValInt;
|
||||
myQImage.setPixel( x, y, qRgba( myGrayValInt, myGrayValInt, myGrayValInt, transparencyLevelInt ));
|
||||
}
|
||||
else //render no data as 100% transparent
|
||||
|
Loading…
x
Reference in New Issue
Block a user