Ginni has Published 1602 Articles

How to track the color in OpenCV using C++?

Ginni

Ginni

Updated on 10-Mar-2021 08:52:23

554 Views

Color tracking is similar to color detection. For tracking purpose, we added extra few lines to calculate the area of the detected object and then track the current position of that area and finally used line() function of OpenCV to show the object's path of motion.The following program demonstrates how ... Read More

How to detect the color using OpenCV in C++?

Ginni

Ginni

Updated on 10-Mar-2021 08:50:24

2K+ Views

We will understand how to detect specific color and track object based on color. Performance of color detection and color detection based tracking system is environment dependent.If you change light of the room or if you change background color, there will be significant effect on color detection.The following program demonstrates ... Read More

How to work with Mouse Events using OpenCV in C++?

Ginni

Ginni

Updated on 10-Mar-2021 08:48:25

1K+ Views

Mouse Events is one of the most useful features of OpenCV. In OpenCV, we can track the mouse pointer's position and track the clicks (right, left and middle-click). OpenCV has a wide application in robotics and computer vision. In robotics and computer vision tracking mouse pointer and clicks are frequently ... Read More

How to rotate a video in OpenCV using C++?

Ginni

Ginni

Updated on 10-Mar-2021 08:47:25

370 Views

Rotating a video is similar to rotate an image. The only difference is instead of load a still picture into an image matrix, we have loaded a video or take video stream from the camera.Here, we are not loading the video but taking a video using the camera. If you ... Read More

How to change the size of an image and add a border in OpenCV using C++?

Ginni

Ginni

Updated on 10-Mar-2021 08:46:49

166 Views

In this topic, we will see another application of trackbar. Here, we will use track-bar to change the size of an image and add a border to the image and change the border's size using the track-bar.Using the following program, we can change the size of an image, add a ... Read More

How to rotate an image in OpenCV using C++?

Ginni

Ginni

Updated on 10-Mar-2021 08:42:40

2K+ Views

Rotating image using built-in functions of OpenCV is an effortless task. To rotate image, we have to use 'highgui.hpp' and 'imgproc.hpp' header files and we will introduce more functions in this program which deal with image rotation.The following program how to rotate an image in OpenCV using C++.Example#include #include #include ... Read More

How to add Track-bar in OpenCV using C++?

Ginni

Ginni

Updated on 10-Mar-2021 08:42:09

679 Views

Track-bars are controllable bars which are used to control various parameters in OpenCV. Using track-bars, we can make it easier and change the parameters graphically. Track-bar removes this limitation and enables to create of dynamic effects using OpenCV.The following program demonstrates how to add track-bars in OpenCV using C++.Example#include #include ... Read More

How to get the FPS value in OpenCV using C++?

Ginni

Ginni

Updated on 10-Mar-2021 08:39:56

831 Views

To get the FPS value, we used the 'get()' command of and 'CAP_PROP_FPS' as the argument of the 'get()'. This argument returns the FPS in integer form.At the starting of the program, we have taken an integer variable named 'FPS'. Then we used FPS = cap.get(CAP_PROP_FPS); to store the FPS ... Read More

How to calculate Elapsed time in OpenCV using C++?

Ginni

Ginni

Updated on 10-Mar-2021 08:37:50

305 Views

Here, we will understand how to calculate the elapsed time using OpenCV.The following program calculates the elapsed time in OpenCV using C++.Example#include//OpenCV header to use VideoCapture class// #include using namespace std; using namespace cv; int main() {    Mat myImage;//Declaring a matrix to load the frames//    namedWindow("Video Player");//Declaring the ... Read More

How to get the position of the current frame in OpenCV using C++?

Ginni

Ginni

Updated on 10-Mar-2021 08:35:34

1K+ Views

The current frame means that you are playing a video and the frame shown now is the current frame. It is also referred to as the active frame. In many application, you can require to get the number of the current frame.The following program reads the position of the current ... Read More

Advertisements