mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-27 00:33:48 -05:00
Fix slight offset in heatmap renderer
This commit is contained in:
parent
554d55d30b
commit
9cf3e7f002
@ -141,8 +141,8 @@ bool QgsHeatmapRenderer::renderFeature( QgsFeature& feature, QgsRenderContext& c
|
||||
for ( QgsMultiPoint::const_iterator pointIt = multiPoint.constBegin(); pointIt != multiPoint.constEnd(); ++pointIt )
|
||||
{
|
||||
QgsPoint pixel = context.mapToPixel().transform( *pointIt );
|
||||
int pointX = pixel.x() / mRenderQuality + 1;
|
||||
int pointY = pixel.y() / mRenderQuality + 1;
|
||||
int pointX = pixel.x() / mRenderQuality;
|
||||
int pointY = pixel.y() / mRenderQuality;
|
||||
for ( int x = qMax( pointX - mRadiusPixels, 0 ); x < qMin( pointX + mRadiusPixels, width ); ++x )
|
||||
{
|
||||
for ( int y = qMax( pointY - mRadiusPixels, 0 ); y < qMin( pointY + mRadiusPixels, height ); ++y )
|
||||
|
Loading…
x
Reference in New Issue
Block a user