Re: [FFmpeg-user] Duplication of time stamps when concatenating .mkv files

2015-02-12 Thread Stefano Sabatini
On date Tuesday 2015-02-03 13:16:00 -0800, Luke Paone wrote:
 Hi,
 
 I am running into some issues when splitting and then concatenating files
 using ffmpeg.
 
 I am using the following command line to split the files:
[...]
 Here is the FFPROBE out put for 2 frames after the merge:
 
 ...
 [FRAME]
 media_type=video
 key_frame=0
 pkt_pts=24958
 pkt_pts_time=24.958000
 pkt_dts=24958
 pkt_dts_time=24.958000
 best_effort_timestamp=24958
 best_effort_timestamp_time=24.958000
 pkt_duration=N/A
 pkt_duration_time=N/A
 pkt_pos=18554505
 pkt_size=25065
 width=1920
 height=1080
 pix_fmt=yuv420p
 sample_aspect_ratio=1:1
 pict_type=P
 coded_picture_number=0
 display_picture_number=0
 interlaced_frame=0
 top_field_first=0
 repeat_pict=0
 [/FRAME]
 [FRAME]
 media_type=video
 key_frame=1
 pkt_pts=24958
 pkt_pts_time=24.958000
 pkt_dts=24958
 pkt_dts_time=24.958000
 best_effort_timestamp=24958
 best_effort_timestamp_time=24.958000
 pkt_duration=N/A
 pkt_duration_time=N/A
 pkt_pos=18579594
 pkt_size=98654
 width=1920
 height=1080
 pix_fmt=yuv420p
 sample_aspect_ratio=1:1
 pict_type=I
 coded_picture_number=0
 display_picture_number=0
 interlaced_frame=0
 top_field_first=0
 repeat_pict=0
 [/FRAME]

My guess is that it could be related to the fact that there is no
frame/packet duration in the first frame. The frame duration can only
be guessed from the next frame (it will be pts2-pts1), but that
information is lost when segmenting the file.

I think you should file an issue on trac, possibly providing a sample
and a reproducible use-case.
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Duplication of time stamps when concatenating .mkv files

2015-02-11 Thread Luke Paone
 Did you try to use the reset_timestamps segment option?

Thanks for responding. I tried this but got the same result. As you
can see from the output I provided in the first post, I used this
command when splitting the video up. This time, I used it when merging
(which I'm guessing is what your suggestion was) and got the same
result. Any other ideas?
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Duplication of time stamps when concatenating .mkv files

2015-02-10 Thread Stefano Sabatini
On date Tuesday 2015-02-03 13:16:00 -0800, Luke Paone wrote:
 Hi,
 
 I am running into some issues when splitting and then concatenating files
 using ffmpeg.
 
 I am using the following command line to split the files:
 
 ffmpeg -i D:\Videos\SwP\sp.webm -codec copy -f segment -segment_time 22
 -reset_timestamps 1 D:\Videos\SplitTest\swp_%04d.webm
 
 and the output is:
[...] 
 My issue is that after the merge, the duration of the video is shorter than
 the original file by 7 frames, which is the number of merges that happened
 between the 8 files that came out after the split. I used mkvinfo to look
 at the details of the .webm file and found that the problem is that ffmpeg
 is giving the first frame of the second part of a merged video the same
 time stamp as the last frame of the first part. Therefore I have duplicate
 time stamps at the point of every merge and I end up loosing a frame
 because of it.
[...]
 Has anyone run into this issue before? Am I missing something? I tried
 looking on the forums and in the ffmpeg trac for a bug but was unable to
 find anything. Any help here would be appreciated.

Did you try to use the reset_timestamps segment option?
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user