Saving segment of video

asked Jun 24 '15

Hi all,

Say I want to want to run a clip through OpenCV's template matching, and if it sees a matching image, save the video segment with the matching image. What would be the relevant function(s) for actually saving the video segment?

Preview: (hide)

Comments

do you want to save the matched part of the image to an image , or the images containing the match to a video file ?

berak gravatar imageberak (Jun 24 '15)edit

I want to split the video up; to save the segment of the video that contains the matched part to one file and the part that doesn't match into a separate file.

iliketurtles gravatar imageiliketurtles (Jun 24 '15)edit
1

I suppose that you want to save just the parts of the video that contains the searched template image, so I would suggest you to do an if template, then save video (using VideoWriter).

thdrksdfthmn gravatar imagethdrksdfthmn (Jun 24 '15)edit

Thank you!

iliketurtles gravatar imageiliketurtles (Jun 25 '15)edit