Patent ID: 8526796

Claim:
A computer-implemented method of a network video recorder (NVR), the method comprising: setting a starting location and an end location of video data in a file, one frame of the video data is recorded in one element of a storage buffer corresponding to the file, the element having an index; setting a starting location and an end location of the video data that coincides with the index of a frame of video data in the storage buffer; receiving a frame of the video data transmitted over a port of the NVR, the frame captured by a video capturing device that is electronically connected to the NVR; upon the condition that the storage buffer corresponding to the file does not have enough space for storing the frame, adjusting the starting location of the storage buffer by one element, and adjusting the starting location of the file to the starting location of the frame recorded in the storage buffer; and upon the condition that the storage buffer corresponding to the file has enough space to record the frame of video data, and the frame of video data is the Intra-frame, recording the frame in the file, adjusting the end location of the file by one frame, and adjusting the end location of the storage buffer by one element.