This post discusses crude but a simple project to familiarize with OpenCV a bit more.
This post will present the code and the next post will give the explanations.
Program:
You can run this script blindly with a blue colored object and draw whatever you want in front of your webcam to have fun.I will be posting the explanations as a seperate post since, its a bit large and requires some time for me prepare it.So keep visiting the blog and I will catch you soon with the next post.
This post will present the code and the next post will give the explanations.
Introduction
This is a small and simple project I did yesterday within a hour or so.Though you may find many applications for this.
The Idea of this project is to trace the path of a object based on its color and draw it on the screen.
Requirements:
The Idea of this project is to trace the path of a object based on its color and draw it on the screen.
Requirements:
- WebCam,
- cv2(OpenCV), pygame, numpy python modules correctly installed
- A specific colored object(I will use a Blue one)
- A background with color other than the objects color.
Program:
download as text tracepath.py.txt |
Sorry viewers I couldn't update for the last week.
ReplyDeleteI just joined for M.Tech away from home,but will catch up with it in two weeks
findContour returns 3 values. So add an extra variable and it's all good to go.
ReplyDelete