Fix the recorded video start time

The event start time already includes the duration of the
pre_event frames. Do not back track the video by a further
pre_event_count.

Signed-off-by: Selva Nair <selva.nair@gmail.com>
This commit is contained in:
Selva Nair 2019-11-03 18:11:55 -05:00
parent 2e7fad68d1
commit dd31279ca3
1 changed files with 1 additions and 1 deletions

View File

@ -875,7 +875,7 @@ int FfmpegCamera::CaptureAndRecord(
// Clear all packets that predate the moment when the recording began // Clear all packets that predate the moment when the recording began
packetqueue->clear_unwanted_packets( packetqueue->clear_unwanted_packets(
&recording, monitor->GetPreEventCount(), mVideoStreamId); &recording, 0, mVideoStreamId);
while ( (queued_packet = packetqueue->popPacket()) ) { while ( (queued_packet = packetqueue->popPacket()) ) {
AVPacket *avp = queued_packet->av_packet(); AVPacket *avp = queued_packet->av_packet();