OpenCV (Open Source Computer Vision) is a computer vision library that contains various functions to perform operations on Images or videos.
OpenCV's application areas include : 1) Facial recognition system 2) motion tracking 3) Artificial neural network 4) Deep neural network 5) video streaming etc.
In Python, one can use an OpenCV library named
CV2. Python does not come with cv2, so user needs to install it separately.
For Windows :pip install opencv-python
For Linux :
sudo apt-get install python-opencv
OpenCv library can be used to perform multiple operations on videos. Let’s try to do something interesting using
CV2. Take a video as input and play it in a reverse mode by breaking the video into frame by frame and simultaneously store that frame in the list. After getting list of frames we perform iteration over the frames. For playing video in reverse mode, we need only to iterate reverse in the list of frames. Use reverse method of the list for reversing the order of frames in the list.
Below is the implementation :
Attention geek! Strengthen your foundations with the Python Programming Foundation Course and learn the basics.
To begin with, your interview preparations Enhance your Data Structures concepts with the Python DS Course.
- Python | Play a video using OpenCV
- OpenCV C++ Program to play a video
- OpenCV - Facial Landmarks and Face Detection using dlib and OpenCV
- MoviePy – Turning on auto play for video clip file
- Python | Create video using multiple images using OpenCV
- Transition from OpenCV 2 to OpenCV 3.x
- Converting Color video to grayscale using OpenCV in Python
- Python - Process images of a video using OpenCV
- Python - Displaying real time FPS at which webcam/video file is processed using OpenCV
- Saving a Video using OpenCV
- Saving Operated Video from a webcam using OpenCV
- OpenCV Python program for Vehicle detection in a Video frame
- Python OpenCV: Capture Video from Camera
- Python OpenCv: Write text on video
- OpenCV C++ Program to blur a Video
- OpenCV | Loading Video
- 10 Interesting modules in Python to play with
- Python VLC MediaPlayer - Setting MRL to play
- Python VLC MediaPlayer - Setting Play Rate
- Python VLC MediaPlayer - Getting Play Rate
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.