I am a beginner in OpenCV. I want to do some image processing on the frames of a video which is being uploaded to my server. I just want to read the available frames and wri
According to the latest updates for OpenCV 3.0 and higher, you need to change the Property Identifiers as follows in the code by Mehran:
cv2.cv.CV_CAP_PROP_POS_FRAMES
to
cv2.CAP_PROP_POS_FRAMES
and same applies to cv2.CAP_PROP_POS_FRAME_COUNT.
cv2.CAP_PROP_POS_FRAME_COUNT
Hope it helps.