OpenCV  3.3.0-rc
Open Source Computer Vision
Video analysis (video module)

Look here in order to find use on your video stream algorithms like: motion extraction, feature tracking and foreground extractions.