[GIS] Rasterize line shapefile

convertqgisraster

I'm trying to convert a line shapefile to a raster image at QGis, but my attempts have been unsuccessful. I've tried to use Raster/Conversion/Rasterize and SAGA/Grid – gridding/Shapes to grid, but to no avail. Is there any other way to accomplish this?

Best Answer

GDAL Rasterize is a tool that might be of use. Here's another link showing GDAL Rasterize combined with Python and the resulting output.

From GDAL Rasterize Help:

The following would burn all "class A" buildings into the output elevation file, pulling the top elevation from the ROOF_H attribute.

gdal_rasterize -a ROOF_H -where 'class="A"' -l footprints footprints.shp city_dem.tif
Related Question