1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
use geom::{Angle, Distance, PolyLine, Pt2D};
use map_model::{BuildingID, ParkingLotID, Traversable, TurnID};
use crate::{AgentID, CarID, PedestrianID, PersonID};
#[derive(Clone)]
pub struct DrawPedestrianInput {
pub id: PedestrianID,
pub pos: Pt2D,
pub facing: Angle,
pub waiting_for_turn: Option<TurnID>,
pub preparing_bike: bool,
pub waiting_for_bus: bool,
pub on: Traversable,
pub person: PersonID,
}
pub struct DrawPedCrowdInput {
pub low: Distance,
pub high: Distance,
pub members: Vec<PedestrianID>,
pub location: PedCrowdLocation,
}
#[derive(Clone)]
pub enum PedCrowdLocation {
Sidewalk(Traversable, bool),
BldgDriveway(BuildingID),
LotDriveway(ParkingLotID),
}
#[derive(Clone)]
pub struct DrawCarInput {
pub id: CarID,
pub waiting_for_turn: Option<TurnID>,
pub status: CarStatus,
pub show_parking_intent: bool,
pub on: Traversable,
pub partly_on: Vec<Traversable>,
pub label: Option<String>,
pub person: Option<PersonID>,
pub body: PolyLine,
}
#[derive(Clone, Copy, PartialEq, Eq)]
pub enum CarStatus {
Moving,
Parked,
}
pub struct UnzoomedAgent {
pub id: AgentID,
pub pos: Pt2D,
pub person: Option<PersonID>,
pub parking: bool,
}