TrafficSim using Unity ECS
Clone or download
Latest commit 84b58b7 Nov 25, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
Assets update readme Nov 25, 2018
Packages add walkable area editor Nov 11, 2018
ProjectSettings add pedestrian Nov 10, 2018
Recordings update readme Nov 25, 2018
.gitattributes Initial commit Oct 31, 2018
.gitignore update readme Nov 25, 2018
LICENSE Initial commit Oct 31, 2018
README.md update readme Nov 25, 2018
app.config Add methods to convert OSM data to roadgraph Nov 1, 2018

README.md

OSMTrafficSim

gif gif gif gif gif

OSMTrafficSim is project to simulate city traffic.

Taking advantage of Unity's recent Entity-Componet-System technology, this project exploits the protential of multi-core processors, simulating 25k cars, 10k pedestrian at 30fps on my laptop.

profile

A BVH is constructed for vehicle's communication. Implementing the method described in Thinking Parallel, Part III: Tree Construction on the GPU

The animation of pedestrian use vertex animation texture tool form Houdini's GameDevelopmentTool. Animation state transition use Markov Chain methods.

The city's model is generated using OSM OpenStreetMap. I takes some tools also form Houdini's GameDevelopmentTool to generate the city's static model.
Road's abstract graph is also generated using OpenStreetMap data, an example data is places in Assets\OSM folder. You can right click on it in Unity's Project window and select ParseToRoadGraph to convert it to data in Unity.

See My Blog Unity ECS and Traffic Simulation | UnityECS架构与交通模拟 and Unity ECS, Swarm Animation And Markov Chain| ECS集群动画与马尔可夫链for more detail

System requirements

  • Unity 2018.2 or later