Fix calculation of heatmap raster size (fix #8194) - merged for further testing