Skip to content

OpenDRIVE import: expose signal facing as headingRad on traffic signs - #95

Merged
kosuke55 merged 1 commit into
mainfrom
feat/signal-heading
Aug 3, 2026
Merged

OpenDRIVE import: expose signal facing as headingRad on traffic signs#95
kosuke55 merged 1 commit into
mainfrom
feat/signal-heading

Conversation

@kosuke55

@kosuke55 kosuke55 commented Aug 3, 2026

Copy link
Copy Markdown
Owner

Summary

Parse <signal orientation> and <signal hOffset> (previously ignored) and expose the world facing of each static sign as ImportedTrafficSign.headingRad (ENU radians): reference-line heading at s, plus pi when orientation="-", plus hOffset.

Renderers drawing road-surface markings encoded as signals (e.g. SgRMArrow* direction arrows) need this to align the artwork with the driving direction; without it arrows can only be drawn unrotated.

  • OSM/Lanelet2 import paths leave the field undefined (optional, non-breaking)
  • Traffic lights are unchanged (drawn upright in 2D)

Tests

  • New: headingRad derivation for orientation +/-, hOffset, and attribute-less defaults (fail-first verified — undefined before the change)
  • Updated the parser record literal for the two new fields
  • Full suite: 310 tests, 306 passed / 4 skipped; tsc build clean

@kosuke55
kosuke55 merged commit 18ef108 into main Aug 3, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant