[GIS] How to use -tap in gdal_rasterize

gdalgdal-rasterize

I have read the gdal documentation for gdal_rasterize. As well as reading the original forum that established -tap (target aligned pixels). I understand -tap is used to make a standard grid (maybe like ArcGIS snap raster) but I do not understand the usage.

When I use gdal_rasterize and I enter -tap what is -tap actually doing to the ouput raster?

I do not seem to be able to point -tap to another raster to use this grid and I do not seem to be able to enter origin coordinates. Gdal_rasterize appears to want me to enter only -tap with no following argument. My assumption is it aligns with 0,0 but this is a guess.

Best Answer

-tap just aligns the grid to the resolution. So, if the resolution is 2m, the cells are aligned to round multiples of 2.