It turns out, we can make our own application with Snapchat like image overlays using Python, OpenCV, and Dlib.
![]() |
| Snapchat like Image Overlays with Dlib, OpenCV, and Python |
So, how do we build it?
- We'll first load the Webcam feed using OpenCV.
- We'll load an image (in our example, and image for the 'eye') to be used as the overlay.
- Use Dlib's face detection to localize the faces, and then use facial landmarks to find where the eyes are.
- Calculate the size and the position of the overlay for each eye.
- Finally, place the overlay image over each eye, resized to the correct size.
Let's start.



