used for video background and foreground object detection