[FFmpeg-trac] #2882(avdevice:closed): ffmpeg can't save h264 stream from v4l2 webcam into file without recoding

FFmpeg trac at avcodec.org
Mon Sep 2 12:18:43 CEST 2013


#2882: ffmpeg can't save h264 stream from v4l2 webcam into file without recoding
------------------------------------+------------------------------------
             Reporter:  pchel       |                    Owner:
                 Type:  defect      |                   Status:  closed
             Priority:  normal      |                Component:  avdevice
              Version:  git-master  |               Resolution:  fixed
             Keywords:  v4l2 h264   |               Blocked By:
             Blocking:              |  Reproduced by developer:  0
Analyzed by developer:  0           |
------------------------------------+------------------------------------

Comment (by cehoyos):

 Replying to [comment:23 pchel]:
 > Replying to [comment:22 cehoyos]:
 > > > {{{
 > > >  frame=  149 fps= 27 q=0.0 Lsize=    3569kB time=00:00:05.02
 bitrate=5823.7kbits/s dup=71 drop=7
 > > > }}}
 > > Looks as if the input frame rate is really ~15fps, don't you agree?
 >
 > I can't agree. When I run the command with mpeg encoding for a minute I
 get following
 >
 > {{{
 > frame=  956 fps= 30 q=0.0 Lsize=   22385kB time=00:00:33.25
 bitrate=5514.9kbits/s dup=475 drop=7
 > video:21817kB audio:529kB subtitle:0 global headers:0kB muxing overhead
 0.172394%
 > }}}
 >
 > So the fps is 30.

 Of the 956 encoded frames, 475 were duplicates (and seven of the original
 frames were dropped), so around 488 frames were sent from the v4l2 device
 in 33.25 seconds, resulting in ~14.6 fps:
 956 - 475 + 7 = 488
 488 frames / 33,24 seconds ~ 14,6fps
 (It is possible that it is more correct not to add the seven dropped
 frames, I don't know for sure.)

 > Also as ffmpeg output
 >
 > {{{
 > Stream #1:0: Video: h264 (Constrained Baseline), yuvj420p(pc), 1920x1080
 [SAR 1:1 DAR 16:9], -5 kb/s, 30 fps, 30 tbr, 1000k tbn, 60 tbc
 > }}}

 Yes, this may be a bug.

-- 
Ticket URL: <https://ffmpeg.org/trac/ffmpeg/ticket/2882#comment:24>
FFmpeg <http://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list