How can I detection features from a video which has already passed through the background subtraction process?

asked 2015-12-03 05:55:28 -0600

isaacsales gravatar image

updated 2015-12-03 06:36:05 -0600

I am trying to detect features from a video has already passed through the background subtraction process but I didn't achieve success and I don't know if it is possible to do this. Can anyone help me? Thanks!

edit retag flag offensive close merge delete

Comments

Start by explaining what you have tried and what problems you've encountered

LorenaGdL gravatar imageLorenaGdL ( 2015-12-03 06:04:07 -0600 )edit

I need to detect car's corners in a video but when I do this from the original video corners that I don't want are detected, for example corners from the background. So I'd know if it is possible to extract the background and then to detect just those features that I need.

isaacsales gravatar imageisaacsales ( 2015-12-03 06:18:32 -0600 )edit

There several background subtraction classes in OpenCV. Initializating and applying them is easy (tweaking might be harder depending on your needs); tutorial here. The output is a binary foreground mask (moving objects = white, static background = 0). Once you have that mask, you can use it to filter your original image (copy with mask or bitwise operation). Read, try, and if you find problems come back. Important note: if using 2.4.x version of OpenCV, both 3 classes are in the video module; if using 3.0.0 version, MOG and GMG were moved to contrib repo.

LorenaGdL gravatar imageLorenaGdL ( 2015-12-03 06:35:48 -0600 )edit