# Revision history [back]

### Getting background subtraction to work

I am trying to use OpenCV's background subtraction in MSVS 2015. When I try to use it I get very unimpressive results compared to what I see online in examples and videos, and I am wondering what I am doing wrong.

It is hard to explain my problem but essentially I am getting a close to blank mask, and the background subtractor seems to focus on the tiniest of differences rather than massive blobs moving across the scene.

Here is the snippet of code I am using, ignore some unused variables:

void find_hand_bs(hand_detection_type type, std::vector<cv::Point> &digits, cv::Mat &input)
{
cv::Mat frame = input.clone(); //current frame