Finding road markings is the first step toward building a self-driving car. If a camera sensor can detect road markings correctly, it can follow the lanes and drive safely.
The main steps for detecting road markings are as follows:
- Loading the image using OpenCV
- Converting the image into grayscale
- Smoothing the image
- Canny edge detection
- Masking the region of interest in an image
- Applying bitwise_and
- Implementing the Hough transform
- Optimizing the detected road markings
- Detecting road markings in an image
- Detecting road masking in a video
We will look at these steps in-depth in the following sections.