raster-buffer query refactored