Skip to content

Commit

Permalink
Fix bug in quantisation code. 8Bit has now a very good visual quality
Browse files Browse the repository at this point in the history
  • Loading branch information
mhugent authored and Marco Hugentobler committed Oct 2, 2012
1 parent 9cd2bb2 commit 45fe0ec
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/mapserver/qgshttprequesthandler.cpp
Expand Up @@ -751,7 +751,7 @@ QRgb QgsHttpRequestHandler::boxColor( const QgsColorBox& box, int boxPixels )
{
currentColor = colorBoxIt->first;
currentPixel = colorBoxIt->second;
weight = currentPixel / boxPixels;
weight = ( double )currentPixel / boxPixels;
avRed += ( qRed( currentColor ) * weight );
avGreen += ( qGreen( currentColor ) * weight );
avBlue += ( qBlue( currentColor ) * weight );
Expand Down

0 comments on commit 45fe0ec

Please sign in to comment.