0

I have a requirement to trace path on the points present in the shapefile which is loaded in Quantum GIS. This should enable the user to specify their own routes within the present network.

There will be existing points and lines present in the shapefile. Whenever the user clicks on the points there should be a line drawn between the points selected and the route should be saved as a shapefile.

I have searched and found in many places of options like pgRouting and shortest path routing and that is not what I require. My need is simple and due to these options being available I'm not able to find a simple solution. It's very much similar to the below question, which does not yield a clear solution.

How to route railcars along railroads?.

I am a Newbie in GIS. Any guidance will be very much appreciated.

  • Is this an academic assignment? Looks like gis.stackexchange.com/questions/76705/… – BradHards Nov 7 '13 at 5:41
  • Brad : This is not any academic assignment. Its a part of a project which i need to complete. The question whicch has been asked in the link specified does not state proper requirement, while i have posted my requirements clearly. Also there has been no answers posted for the question mentioned in the link and was closed. Please guide. – sTg Nov 7 '13 at 5:46
  • I don't have an answer - your question is too broad for me. Perhaps you would care to edit your question with what research you've already done, what tests you've performed, what the results were, what still needs to be done. Surely you didn't just come to gis.SE and ask someone else to do your work for you without making any attempt yourself? – BradHards Nov 7 '13 at 5:49
  • Brad:I have edited the question based on the research i have done – sTg Nov 7 '13 at 6:00
3

I've written a routing script for QGIS Processing based on the core network analysis library. It expects a point layer and a network layer as input and returns a route between the points. To add the interactive aspect you describe, you'll have to extend the code.

enter image description here

enter image description here

0

Your question is not about routes - its about lines (polylines) in shapefiles.

Create a new shapefile as shown at http://www.qgis.org/en/docs/user_manual/working_with_vector/editing_geometry_attributes.html#creating-new-vector-layers

http://www.qgis.org/en/docs/gentle_gis_introduction/data_capture.html tells you how to capture data.

You might like to set up your preferences as shown at http://www.qgis.org/en/docs/user_manual/working_with_vector/editing_geometry_attributes.html to get a nice behaviour.

More information on QGIS is available at http://www.qgis.org/en/docs/index.html

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.