[GIS] QGIS 2.8 Convert a vector to a raster layer

qgisqgis-2.8rastervector

When I change a vector layer to raster using raster button->converse->Vector rasterization in QGIS2.8. I get only a black picture.
Why is that so and how can I convert a vector layer to a raster layer.

Best Answer

Rasterization depends of the field that you select. For example, in the following case I selected (in vector layer point_2) the 'field' field whose values are all 0. The result, point_2_raster.tif, is the same that you are obtaining (a black picture):

enter image description here

However, if the 'id' field is selected, whose values are between 1 and 5, the result (point_raster.tif) is totally different:

enter image description here

It could be your problem.