Wow, that was fast. I was just about to reply the I found out I should put
the ports as starting points. And that is clearly stated in the manual

https://grass.osgeo.org/grass70/manuals/r.cost.html#shortest-distance-surfaces

Thanks all
Cheers

On Fri, Nov 10, 2017 at 2:21 PM Moritz Lennert <[email protected]>
wrote:

> Le Fri, 10 Nov 2017 16:03:45 +0000,
> Daniel Victoria <[email protected]> a écrit :
>
> > Hi list,
> >
> > I want to calculate a cost of getting from any cell in my raster to
> > some ports, considering roads network, and I though r.cost could
> > solve this.
> >
> > What I have is:
> > 1) Cost raster map with cost per cell (10 for normal cells, 1 if it's
> > a road)
> > 2) vector map containing several ports
> > 3) start_raster has the same extent of the cost raster, but all cells
> > == 1
> >
> > This is the command I'm using
> > r.cost input=cost_map output=cum_cost stop_points=ports
> > start_raster=my_region
>
> Just try it with r.cost input=cost_map output=cum_cost
> start_points=ports
>
> Moritz
>
_______________________________________________
grass-user mailing list
[email protected]
https://lists.osgeo.org/mailman/listinfo/grass-user

Reply via email to