Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sumo-user] R: Locating cars around certain coordinates

If the point of interest is an actual POI or some other simulation objects supported by TraCI then you can use the 'subscribeContext' function to efficiently retrieve objects of a specified type (e.g. cars) in a specified radius.
See http://sumo.dlr.de/wiki/TraCI/Object_Context_Subscription
Note, that you can add POIs via TraCI.

regards,
Jakob

2018-07-25 13:02 GMT+02:00 Stefano Niero <stefano.niero@xxxxxxxxxx>:

Sorry for the disturb, I solved the problem the other way around: calculating the distance for each car from my point of interest and if this distance is below a certain radius the vehicle is added to the list. If you have faster solutions they are still welcome.

 

Stefano

 

Da: Stefano Niero
Inviato: 25 July 2018 11:11
A: 'Sumo project User discussions' <sumo-user@xxxxxxxxxxx>
Oggetto: Locating cars around certain coordinates

 

Hi,

I was wondering whether it was possible, given x and y coordinates and the radius, to have a list of all the vehicles within the circumference described.

 

Best Regards

Stefano

 


_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/sumo-user



Back to the top