Skip to main content

Module obstacle

Module obstacle 

Source
Expand description

Cross-domain obstacle trait.

The critical challenge in a coupled crowd-plus-traffic simulation is that crowd models must see vehicles as moving obstacles, and vehicle models must see pedestrians as obstacles. Neither domain crate should depend on the other.

This module defines a tiny abstract interface both sides can implement in thin adapter types.

Structs§

ObstacleSnapshot
Instantaneous snapshot of an obstacle’s bounding circle and velocity in 3-D. Implementations should project to z = 0 if they live in 2-D.
PedestrianObstacle
Thin obstacle adapter for a rustsim_crowd::Pedestrian.
VehicleObstacle
Thin obstacle adapter for a rustsim_vehicle::Vehicle.

Enums§

ObstacleKind
Kind of an obstacle, used for priority and styling.

Traits§

Obstacle
Any entity that can expose itself as an obstacle to foreign domains.