[Qgis-user] Extract lines from raster
Siki Zoltan
siki at agt.bme.hu
Mon Aug 18 23:17:35 PDT 2014
Dear Matt,
there is Polygonize menu option in Raster/Convert. It uses gdal and
creates vector polygons for all connected regions of pixels in the raster
sharing a common pixel value. Probably this is not the best for you if you
have lines in your raster. For such tasks I usually use GRASS commands
0. r.in.gdal import your raster into GRASS
1. r.thin to narrow raster lines to 1 pixel
2. r.to.vect to create line features from raster
3. v.generalize to simplify vector lines (there are a lots of methods
available)
4. v.out.org export your vector (you can open and edit GRASS maps in QGIS
too)
Simplification is available also in QGIS see:
Vector menu -> Geometry tools -> Simplify geometries
Regards,
Zoltan
On Tue, 19 Aug 2014, Matt Boyd wrote:
> Hi List,
> I've got a scanned map I want to extract / digitise the contours from as
> lines.
> The lines are all black and if I can get everything that's black into a
> shapefile I'd be able toedit and assign values once there. Is there
> anything in qgis that coudl do this? I had a quick look at orfeo but for
> some reason the website is down today.
>
> Thanks
> Matt
>
More information about the Qgis-user
mailing list