scenic.formats.opendrive.xodr_parser
Parser for OpenDRIVE (.xodr) files.
Summary of Module Members
Functions
|
|
|
Classes
An Euler spiral with curvature varying linearly between CURV0 and CURV1. |
|
A curve defined by the cubic polynomial a + bu + cu^2 + du^3. |
|
Geometric elements which compose road reference lines. |
|
|
|
|
|
|
|
A line segment between (x0, y0) and (x1, y1). |
|
A curve defined by the parametric equations u = a_u + b_up + c_up^2 + d_up^3, v = a_v + b_vp + c_vp^2 + d_up^3, with p in [0, p_range]. |
|
Cubic polynomial. |
|
|
|
Indicates Roads a and b, with ids id_a and id_b respectively, are connected. |
|
|
|
Traffic lights, stop signs, etc. |
|
|
Exceptions
|
Member Details
- class Curve(x0, y0, hdg, length)[source]
Geometric elements which compose road reference lines. See the OpenDRIVE Format Specification for coordinate system details.
- to_points(num, extra_points=[])[source]
Sample NUM evenly-spaced points from curve.
Points are tuples of (x, y, s) with (x, y) absolute coordinates and s the arc length along the curve. Additional points at s values in extra_points are included if they are contained in the curve (unless they are extremely close to one of the equally-spaced points).
- class Cubic(x0, y0, hdg, length, a, b, c, d)[source]
Bases:
Curve
A curve defined by the cubic polynomial a + bu + cu^2 + du^3. The curve starts at (X0, Y0) in direction HDG, with length LENGTH.
- class ParamCubic(x0, y0, hdg, length, au, bu, cu, du, av, bv, cv, dv, p_range=1)[source]
Bases:
Curve
A curve defined by the parametric equations u = a_u + b_up + c_up^2 + d_up^3, v = a_v + b_vp + c_vp^2 + d_up^3, with p in [0, p_range]. The curve starts at (X0, Y0) in direction HDG, with length LENGTH.
- class Clothoid(x0, y0, hdg, length, curv0, curv1)[source]
Bases:
Curve
An Euler spiral with curvature varying linearly between CURV0 and CURV1. The spiral starts at (X0, Y0) in direction HDG, with length LENGTH.