Browse Source
feat: Add vehicle dimensions visualization and enhance track risk coloring
feat: Add vehicle dimensions visualization and enhance track risk coloring
Vehicle Dimensions: - Added "Show Dimensions" toggle to the display settings. - Implemented `drawObjectDimensions` in `drawUtils.js` to render object extents as oriented rectangles based on `objectExtentRadii` and `objectExtentAngle`. - Updated `radarSketch.js` to draw dimensions when enabled. - Ensured dimensions and covariance ellipses are drawn at the `correctedPosition` for accurate alignment with track markers. Track Visualization: - Updated `drawTrajectories` to prioritize the `risk` property on track logs for coloring (0=Low/Blue, 1=Medium/Orange, 2=High/Red). - Added fallback to `ttcCategoryTimeline` for backward compatibility. - Fixed off-by-one error in trajectory history filtering to prevent drawing future points. Frame Synchronization & UI: - Refactored frame number display logic across Overlays, Data Explorer, and Timeline. - UI now displays the actual `frameIdx` from the data source instead of the internal array index, resolving discrepancies between the Data Explorer and the main view.refactor/sync-centralize
5 changed files with 124 additions and 40 deletions
-
2steps/index.html
-
1steps/src/dom.js
-
71steps/src/drawUtils.js
-
34steps/src/p5/radarSketch.js
-
4steps/src/ui.js
Write
Preview
Loading…
Cancel
Save
Reference in new issue