Hi,
I'm capturing video streams from IP cameras using avconv with the following
command line options:
avconv -i rtsp://192.168.0.16 -c copy -map 0:0 -f segment -segment_time
1800 -segment_format mkv "TLC01_%d.mkv"
It works great, I get exactly segments of 30 minutes duration, but I have a
problem when reproducing the segments with common videoplayers, such as VLC
because the reported clip duration is wrong i.e. about 60 hours instead of
30 minutes. Is there something wrong in my command line ?
Here is the output of avconv:
avconv version 11.6, Copyright (c) 2000-2014 the Libav developers
built on Mar 18 2016 10:37:11 with gcc 4.8.1 (GCC)
[rtsp @ 0x11420a0] Estimating duration from bitrate, this may be inaccurate
Input #0, rtsp, from 'rtsp://192.168.0.16':
Metadata:
title : Media Presentation
Duration: N/A, start: 0.009978, bitrate: N/A
Stream #0.0: Video: h264 (Main), yuv420p, 704x576, 20.25 fps, 90k tbn,
40 tbc
[matroska @ 0x12e8fc0] Using AVStream.codec.time_base as a timebase hint to
the muxer is deprecated. Set AVStream.time_base instead.
[matroska @ 0x12e8fc0] Codec for stream 0 does not use global headers but
container format requires global headers
Output #0, segment, to 'TLC01_%d.mkv':
Metadata:
title : Media Presentation
encoder : Lavf56.1.0
Stream #0.0: Video: libx264, yuv420p, 704x576, q=2-31, 90k tbn, 90k tbc
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Press ctrl-c to stop encoding
frame= 235 fps= 22 q=-1.0 size= 0kB time=11.69 bitrate= 0.0kbits/s
....
And here is the output of mkvinfo:
+ EBML head
|+ EBML version: 1
|+ EBML read version: 1
|+ EBML maximum ID length: 4
|+ EBML maximum size length: 8
|+ Doc type: matroska
|+ Doc type version: 2
|+ Doc type read version: 2
+ Segment, size 97952431
|+ Seek head (subentries will be skipped)
|+ EbmlVoid (size: 147)
|+ Segment information
| + Timecode scale: 1000000
| + Muxing application: Lavf56.1.0
| + Writing application: Lavf56.1.0
| + Segment UID: 0x53 0x89 0x6c 0x0e 0x4d 0x2f 0x53 0x7d 0x80 0xe9 0x62
0x94 0xff 0x89 0x85 0x06
| + Duration: 216005.674s (60:00:05.674)
|+ Segment tracks
Thank you in advance, any help will be appreciated
Regards,
Federico
_______________________________________________
libav-tools mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-tools