3 using System.Collections.Generic;
14 private const double GeneratorCircleRadius = 2.0;
25 set { geometricTopology = value; }
38 protected override void Render(Point currentMouseLocation)
46 internal void RenderTopology()
48 using (DrawingContext dc = visual.RenderOpen())
51 foreach (var lane
in geometricTopology.
Lanes)
55 dc.DrawLine(
new Pen(Brushes.Black, 1),
56 TransformRealWorldPoint(lane.StartNode.Location),
57 TransformRealWorldPoint(lane.EndNode.Location));
61 BezierLane bezierLane = lane as BezierLane;
63 TransformRealWorldPoint(bezierLane.
StartNode.Location),
64 TransformRealWorldPoint(bezierLane.
EndNode.Location),
69 if (lane.StartNode.ContainsGenerator)
71 dc.DrawEllipse(Brushes.Blue, null, TransformRealWorldPoint(lane.StartNode.Location),
72 GeneratorCircleRadius, GeneratorCircleRadius);
Class representing geometric topology of road network.
Geometric topology renderer.
Represents single straight lane.
Base class for drawing visual renderer.
StartNode StartNode
Node on the input end of lane.
Point SecondControlLocation
Second control location of point.
Represents single bezier lane.
Node EndNode
Node on the output end of lane.
ReadOnlyCollection< Lane > Lanes
Lanes in geometric topology. </summary
Class for creating geometry with bezier curve from canvas-coordinated points.
Point FirstControlLocation
First control location of point.
override void Render(Point currentMouseLocation)
Redraw geometric topology on drawing visual. Current mouse location