[FFmpeg-user] -f segment skip the last B-frames

Vincent Vilain vilain.vincent at gmail.com
Wed Mar 4 13:52:15 CET 2015


I capture an internal rtp stream in mpeg2 at 25fps with this gop structure
IBBPBBPBBPBB with this command
ffmpeg -i [rtp_stream] -vcodec copy -acodec copy -sn -t 300 -f segment
-segment_format mpeg2ts -segment_time 60 -y [path]\[baseName]%03d.ts

this works fine but when I analyse the last gop of each chunk the 2 last
b-frames are missing (the last gop is IBBPBBPBBP) and the total number of
frames is 1498 (should be 1500 = 25*60 = fps * segment_time).

I've tried several options:

   - -flags +cgop
   - -flags -cgop
   - -force_key_frames 0.02
   - -segment_time_delta 0.05
   - replace -segment_time 60 by -segment_frames 1500


but no change about the last gop.

does anyone has a clue?

PS: before anyone mention it I know that the last B-frames refers to the
I-frame that is in another file

-- 
V. VILAIN


More information about the ffmpeg-user mailing list