Skip to content

Latest commit

 

History

History
41 lines (29 loc) · 1.26 KB

README.md

File metadata and controls

41 lines (29 loc) · 1.26 KB

Lane Departure Warning

Code can be linked as part of an iOS application or run as a standalone desktop application (for debug purposes).

Performs well in real time on iPhone 6.

Built for own entertaiment.

Approach

↓ Setup perspective
↓ Feed frame from file or camera
↓ Warp perspective (road → screen)
↓ Grayscale
↓ Blur
↓ Canny
↓ Hough lines
↓ Detect lanes
↓ Unwrap perspective for lane points coordinates (screen → road)
↓ Get distance from car bounds to lanes (in inches)
↓ Process data, update state, fire events to outside world
↺ Repeat

Demo

City:
day

Highway:
straight_night

Changing lane:
changing_lane

Taking exit:
taking_exit

Perspective transform/dashboard:
perspective2

Enjoy!