Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sumo-user] Question about GetLanePosition and GetPosition

- getPosition refers to the Cartesian coordinate plane. The origin point of 0,0 is usually the lower right network corner so coordinates are mostly positive. However, nothing prevents a user from shifting his network or adding new edges in another quadrant (and nothing bad comes of it).
- getLanePosition is the distance from the start of the current lane so this value is reset to 0 everytime the vehicle drives onto a new lane.
- The best way to obtain a distance to a point along the current route is to call `traci.vehicle.getDrivingDistance` . Otherwise you're better of with `traci.simulation.findRoute` which will return the route to that location as well as it's length.

Am Fr., 3. März 2023 um 06:16 Uhr schrieb Sona S <ms.sona.12@xxxxxxxxx>:
Hi Everyone,

I am not able to get the concept of GetLanePosition and GetPosition in Sumo. I want to check the vehicle's distance from a specific junction, for example, Junction J1. So I can calculate the vehicle's arrival time. Which one should I use?
One more thing,
What is the meaning of negative values in GetPosition?
image.png

Regards,
Shraddha
 

_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/sumo-user

Back to the top