Detection of the object in the video is a primary task of all video-processing-based applications. It is one of the challenging areas in computer vision. The paper presents a novel MATLAB-based object detection application based on an improved Gaussian Mixture Model. Gaussian Mixture Model with post-processing applied here for segmentation of foreground from background. The application is divided into three modules pre-processing, detection and post-processing. The morphological gradient filter uses here for segmenting the foreground objects from the background. The proposed method was tested for various video sequences with challenges and proved that the approach performs well for the majority video sequences.