Opened 12 years ago

Last modified 12 years ago

#1446 new defect

Output via rtsp results in logs not displaying frame size nor bitrate

Reported by: Michael Smithng Owned by:
Priority: normal Component: undetermined
Version: unspecified Keywords: rtsp rtmp
Cc: Michael Niedermayer Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Attempt to push output via rtsp and one can observe that the log contains no details regarding size nor bitrate.

Example:

frame=1221110 fps= 29 q=36.0 size=       0kB time=11:18:22.36 bitrate=   0.0kbits/s dup=1220 drop=0
frame=1221125 fps= 29 q=36.0 size=       0kB time=11:18:22.86 bitrate=   0.0kbits/s dup=1220 drop=0
frame=1221140 fps= 29 q=36.0 size=       0kB time=11:18:23.36 bitrate=   0.0kbits/s dup=1220 drop=0
frame=1221156 fps= 29 q=36.0 size=       0kB time=11:18:23.90 bitrate=   0.0kbits/s dup=1220 drop=0
frame=1221171 fps= 29 q=36.0 size=       0kB time=11:18:24.40 bitrate=   0.0kbits/s dup=1220 drop=0
./ffmpeg -i $SOURCE -threads 2 -b:v 500k -bt 500k -deinterlace -r 30 -vcodec libx264 -b:a 64k -acodec libfaac -ar 44100 -s 720x480 -x264opts keyint=30:min-keyint=15 -f rtsp -rtsp_transport tcp -muxdelay 0.1 "rtsp://user:password@wowza.server.com/stream/path.sdp" 2> ./ffmpeg-log.out

All code has been compiled from available download on ffmpeg.org, however; I've not compiled from the git repo, but this has been present since ffmpeg-0.9.1 or earlier.

ffmpeg version 0.9.1, Copyright (c) 2000-2012 the FFmpeg developers
  built on Jan  9 2012 16:42:51 with gcc 4.2.1 (Apple Inc. build 5666) (dot 3)
  configuration: --logfile=./config_64.log --disable-ffplay --enable-gpl --enable-nonfree --enable-libx264 --enable-libfaac --enable-libmp3lame --arch=x86_64
  libavutil    51. 32. 0 / 51. 32. 0
  libavcodec   53. 42. 4 / 53. 42. 4
  libavformat  53. 24. 2 / 53. 24. 2
  libavdevice  53.  4. 0 / 53.  4. 0
  libavfilter   2. 53. 0 /  2. 53. 0
  libswscale    2.  1. 0 /  2.  1. 0
  libpostproc  51.  2. 0 / 51.  2. 0
[dv @ 0x10180e800] Estimating duration from bitrate, this may be inaccurate
Input #0, dv, from '/var/run/raw.dv':
  Duration: N/A, start: 0.000000, bitrate: 28771 kb/s
    Stream #0:0: Video: dvvideo, yuv411p, 720x480, 28771 kb/s, SAR 32:27 DAR 16:9, 29.97 tbr, 29.97 tbn, 29.97 tbc
    Stream #0:1: Audio: pcm_s16le, 32000 Hz, 2 channels, s16, 1024 kb/s
    Stream #0:2: Audio: pcm_s16le, 32000 Hz, 2 channels, s16, 1024 kb/s
Incompatible pixel format 'yuv411p' for codec 'libx264', auto-selecting format 'yuv422p'
[buffer @ 0x101111d40] w:720 h:480 pixfmt:yuv411p tb:1/1000000 sar:32/27 sws_param:
[buffersink @ 0x101112aa0] auto-inserting filter 'auto-inserted scale 0' between the filter 'src' and the filter 'out'
[scale @ 0x101112d80] w:720 h:480 fmt:yuv411p -> w:720 h:480 fmt:yuv422p flags:0x4
[libx264 @ 0x10185e400] using SAR=32/27
[libx264 @ 0x10185e400] using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.1 Cache64
[libx264 @ 0x10185e400] profile High 4:2:2, level 3.0, 4:2:2 8-bit
[libx264 @ 0x10185e400] 264 - core 119 - H.264/MPEG-4 AVC codec - Copyleft 2003-2011 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=3 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=30 keyint_min=15 scenecut=40 intra_refresh=0 rc_lookahead=30 rc=abr mbtree=1 bitrate=250 ratetol=1.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, rtsp, to 'rtsp://[...]':
  Metadata:
    encoder         : Lavf53.24.2
    Stream #0:0: Video: h264, yuv422p, 720x480 [SAR 32:27 DAR 16:9], q=-1--1, 250 kb/s, 90k tbn, 30 tbc  
    Stream #0:1: Audio: aac, 44100 Hz, 2 channels, s16, 64 kb/s
Stream mapping:
  Stream #0:0 -> #0:0 (dvvideo -> libx264)
  Stream #0:1 -> #0:1 (pcm_s16le -> libfaac)
Press [q] to stop, [?] for help
frame=360449 fps= 30 q=34.0 size=       0kB time=03:20:13.66 bitrate=   0.0kbits/s dup=360 drop=0
[...]
frame=1221110 fps= 29 q=36.0 size=       0kB time=11:18:22.36 bitrate=   0.0kbits/s dup=1220 drop=0
frame=1221125 fps= 29 q=36.0 size=       0kB time=11:18:22.86 bitrate=   0.0kbits/s dup=1220 drop=0
frame=1221140 fps= 29 q=36.0 size=       0kB time=11:18:23.36 bitrate=   0.0kbits/s dup=1220 drop=0
frame=1221156 fps= 29 q=36.0 size=       0kB time=11:18:23.90 bitrate=   0.0kbits/s dup=1220 drop=0
frame=1221171 fps= 29 q=36.0 size=       0kB time=11:18:24.40 bitrate=   0.0kbits/s dup=1220 drop=0

With v0.11... and slightly modified command line

ffmpeg -i $SOURCE -threads 0 -b:v 240k -bt 240k -r 15 -filter:v yadif=1:1 -c:v libx264 -profile:v baseline -level 3.0 -pix_fmt yuv420p -c:a libfaac -b:a 64k -ar 44100 -s 320x240 -x264opts keyint=15:min-keyint=45 -f rtsp -rtsp_transport tcp -muxdelay 0.1 rtsp://user:password@wowza.server.com/stream/path.sdp" 2> ./ffmpeg-log.out

Results in the same output:

ffmpeg version 0.11 Copyright (c) 2000-2012 the FFmpeg developers
  built on Jun  4 2012 12:36:38 with gcc 4.2.1 (Apple Inc. build 5666) (dot 3)
  configuration: --logfile=./config_64.log --disable-ffplay --enable-gpl --enable-nonfree --enable-libx264 --enable-libfaac --enable-libmp3lame --arch=x86_64
  libavutil      51. 54.100 / 51. 54.100
  libavcodec     54. 23.100 / 54. 23.100
  libavformat    54.  6.100 / 54.  6.100
  libavdevice    54.  0.100 / 54.  0.100
  libavfilter     2. 77.100 /  2. 77.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 15.100 /  0. 15.100
  libpostproc    52.  0.100 / 52.  0.100
[dv @ 0x10180e800] Estimating duration from bitrate, this may be inaccurate
Guessed Channel Layout for  Input Stream #0.1 : stereo
Input #0, dv, from '/var/run/raw.dv':
  Duration: N/A, start: 0.000000, bitrate: 28771 kb/s
    Stream #0:0: Video: dvvideo, yuv411p, 720x480, 28771 kb/s, SAR 8:9 DAR 4:3, 29.97 tbr, 29.97 tbn, 29.97 tbc
    Stream #0:1: Audio: pcm_s16le, 48000 Hz, stereo, s16, 1536 kb/s
[buffer @ 0x101212660] w:720 h:480 pixfmt:yuv411p tb:1001/30000 sar:8/9 sws_param:flags=2
[buffersink @ 0x101213260] No opaque field provided
[scale @ 0x101213440] w:720 h:480 fmt:yuv411p sar:8/9 -> w:720 h:480 fmt:yuv420p sar:8/9 flags:0x4
[aformat @ 0x101216220] auto-inserting filter 'auto-inserted resampler 0' between the filter 'src' and the filter 'aformat'
[aresample @ 0x101216820] chl:stereo fmt:s16 r:48000Hz -> chl:stereo fmt:s16 r:44100Hz
[libx264 @ 0x10180f400] using SAR=8/9
[libx264 @ 0x10180f400] using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.1 Cache64
[libx264 @ 0x10180f400] profile Constrained Baseline, level 3.0
[libx264 @ 0x10180f400] 264 - core 125 - H.264/MPEG-4 AVC codec - Copyleft 2003-2012 - http://www.videolan.org/x264.html - options: cabac=0 ref=3 deblock=1:0:0 analyse=0x1:0x111 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=3 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=0 keyint=15 keyint_min=45 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=abr mbtree=1 bitrate=250 ratetol=1.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, rtsp, to 'rtsp://[...]':
  Metadata:
    encoder         : Lavf54.6.100
    Stream #0:0: Video: h264, yuv420p, 720x480 [SAR 8:9 DAR 4:3], q=-1--1, 250 kb/s, 90k tbn, 15 tbc
    Stream #0:1: Audio: aac, 44100 Hz, stereo, s16, 64 kb/s
Stream mapping:
  Stream #0:0 -> #0:0 (dvvideo -> libx264)
  Stream #0:1 -> #0:1 (pcm_s16le -> libfaac)
Press [q] to stop, [?] for help
frame=   18 fps= 18 q=0.0 size=       0kB time=00:00:00.00 bitrate=   0.0kbits/s dup=0 drop=12
frame=   26 fps= 17 q=0.0 size=       0kB time=00:00:00.00 bitrate=   0.0kbits/s dup=0 drop=20
frame=   33 fps= 16 q=0.0 size=       0kB time=00:00:00.00 bitrate=   0.0kbits/s dup=0 drop=27
frame=   41 fps= 16 q=0.0 size=       0kB time=00:00:00.00 bitrate=   0.0kbits/s dup=0 drop=35
frame=   48 fps= 16 q=44.0 size=       0kB time=00:00:00.26 bitrate=   0.0kbits/s dup=0 drop=43
frame=   56 fps= 16 q=37.0 size=       0kB time=00:00:00.80 bitrate=   0.0kbits/s dup=0 drop=50
frame=   63 fps= 16 q=34.0 size=       0kB time=00:00:01.26 bitrate=   0.0kbits/s dup=0 drop=58
frame=   71 fps= 16 q=32.0 size=       0kB time=00:00:01.80 bitrate=   0.0kbits/s dup=0 drop=65
frame=   78 fps= 15 q=33.0 size=       0kB time=00:00:02.26 bitrate=   0.0kbits/s dup=0 drop=73
frame=   86 fps= 16 q=34.0 size=       0kB time=00:00:02.80 bitrate=   0.0kbits/s dup=0 drop=80
frame=   94 fps= 16 q=36.0 size=       0kB time=00:00:03.33 bitrate=   0.0kbits/s dup=0 drop=88
frame=  101 fps= 15 q=37.0 size=       0kB time=00:00:03.80 bitrate=   0.0kbits/s dup=0 drop=96
frame=  109 fps= 15 q=37.0 size=       0kB time=00:00:04.33 bitrate=   0.0kbits/s dup=0 drop=103
frame=  117 fps= 15 q=36.0 size=       0kB time=00:00:04.86 bitrate=   0.0kbits/s dup=0 drop=111
Que input is backward in time
[rtsp @ 0x10180ee00] Audio timestamp 707547 < 708440 invalid, cliping
frame=  122 fps= 14 q=-1.0 Lsize=       0kB time=00:00:07.89 bitrate=   0.0kbits/s dup=0 drop=116    
video:230kB audio:61kB global headers:0kB muxing overhead -100.000000%
[libx264 @ 0x10180f400] frame I:3     Avg QP:29.76  size:  7183
[libx264 @ 0x10180f400] frame P:119   Avg QP:31.61  size:  1797
[libx264 @ 0x10180f400] mb I  I16..4: 76.4%  0.0% 23.6%
[libx264 @ 0x10180f400] mb P  I16..4:  9.1%  0.0%  1.4%  P16..4: 25.7%  2.9%  0.7%  0.0%  0.0%    skip:60.2%
[libx264 @ 0x10180f400] final ratefactor: 30.48
[libx264 @ 0x10180f400] coded y,uvDC,uvAC intra: 12.7% 29.4% 1.4% inter: 2.2% 4.6% 0.0%
[libx264 @ 0x10180f400] i16 v,h,dc,p: 50% 25% 10% 16%
[libx264 @ 0x10180f400] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 23% 32% 26%  5%  3%  4%  3%  4%  2%
[libx264 @ 0x10180f400] i8c dc,h,v,p: 73% 11% 15%  1%
[libx264 @ 0x10180f400] ref P L0: 69.1% 21.1%  9.9%
[libx264 @ 0x10180f400] kb/s:231.50

It's obviously keeping track of the output kbps given the last line [libx264 @ 0x10180f400] kb/s:231.50 but why it's not being written to the log is currently beyond me.

Using the same binary and command, but output via rtmp seems to report correctly (to bad I can't use rtmp in my application use case.):

ffmpeg version 0.11 Copyright (c) 2000-2012 the FFmpeg developers
  built on Jun  1 2012 17:41:17 with gcc 4.2.1 (Apple Inc. build 5666) (dot 3)
  configuration: --logfile=./config_64.log --disable-ffplay --enable-gpl --enable-nonfree --enable-libx264 --enable-libfaac --enable-libmp3lame  --arch=x86_64
  libavutil      51. 54.100 / 51. 54.100
  libavcodec     54. 23.100 / 54. 23.100
  libavformat    54.  6.100 / 54.  6.100
  libavdevice    54.  0.100 / 54.  0.100
  libavfilter     2. 77.100 /  2. 77.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 15.100 /  0. 15.100
  libpostproc    52.  0.100 / 52.  0.100
[dv @ 0x10180e800] Estimating duration from bitrate, this may be inaccurate
Guessed Channel Layout for  Input Stream #0.1 : stereo
Input #0, dv, from '/var/run/raw.dv':
  Duration: N/A, start: 0.000000, bitrate: 28771 kb/s
    Stream #0:0: Video: dvvideo, yuv411p, 720x480, 28771 kb/s, SAR 8:9 DAR 4:3, 29.97 tbr, 29.97 tbn, 29.97 tbc
    Stream #0:1: Audio: pcm_s16le, 48000 Hz, stereo, s16, 1536 kb/s
[buffer @ 0x101114020] w:720 h:480 pixfmt:yuv411p tb:1001/30000 sar:8/9 sws_param:flags=2
[buffersink @ 0x101112580] No opaque field provided
[yadif @ 0x101114f40] mode:1 parity:1 auto_enable:0
[scale @ 0x1011146e0] w:720 h:480 fmt:yuv411p sar:8/9 -> w:320 h:240 fmt:yuv420p sar:1/1 flags:0x4
[aformat @ 0x101120220] auto-inserting filter 'auto-inserted resampler 0' between the filter 'src' and the filter 'aformat'
[aresample @ 0x101120760] chl:stereo fmt:s16 r:48000Hz -> chl:stereo fmt:s16 r:44100Hz
[libx264 @ 0x10180f400] using SAR=1/1
[libx264 @ 0x10180f400] using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.1 Cache64
[libx264 @ 0x10180f400] profile Constrained Baseline, level 3.0
[libx264 @ 0x10180f400] 264 - core 119 - H.264/MPEG-4 AVC codec - Copyleft 2003-2011 - http://www.videolan.org/x264.html - options: cabac=0 ref=3 deblock=1:0:0 analyse=0x1:0x111 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=4 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=0 keyint=45 keyint_min=23 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=abr mbtree=1 bitrate=240 ratetol=1.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, flv, to 'rtmp://[...]':
  Metadata:
    encoder         : Lavf54.6.100
    Stream #0:0: Video: h264 ([7][0][0][0] / 0x0007), yuv420p, 320x240 [SAR 1:1 DAR 4:3], q=-1--1, 240 kb/s, 1k tbn, 15 tbc
    Stream #0:1: Audio: aac ([10][0][0][0] / 0x000A), 44100 Hz, stereo, s16, 64 kb/s
Stream mapping:
  Stream #0:0 -> #0:0 (dvvideo -> libx264)
  Stream #0:1 -> #0:1 (pcm_s16le -> libfaac)
Press [q] to stop, [?] for help
frame=    9 fps=0.0 q=0.0 size=       0kB time=00:00:00.00 bitrate=   0.0kbits/s dup=0 drop=21
frame=   17 fps= 17 q=0.0 size=       0kB time=00:00:00.00 bitrate=   0.0kbits/s dup=0 drop=43
frame=   25 fps= 16 q=0.0 size=       0kB time=00:00:00.00 bitrate=   0.0kbits/s dup=0 drop=67
frame=   32 fps= 16 q=0.0 size=       0kB time=00:00:00.00 bitrate=   0.0kbits/s dup=0 drop=90
frame=   40 fps= 16 q=0.0 size=       0kB time=00:00:00.00 bitrate=   0.0kbits/s dup=0 drop=112
frame=   48 fps= 16 q=37.0 size=      22kB time=00:00:00.20 bitrate= 887.2kbits/s dup=0 drop=136
frame=   55 fps= 15 q=37.0 size=      40kB time=00:00:00.66 bitrate= 496.7kbits/s dup=0 drop=159
frame=   63 fps= 15 q=32.0 size=      48kB time=00:00:01.20 bitrate= 329.2kbits/s dup=0 drop=181
frame=   70 fps= 15 q=29.0 size=      57kB time=00:00:01.66 bitrate= 279.5kbits/s dup=0 drop=204
frame=   78 fps= 15 q=27.0 size=      71kB time=00:00:02.20 bitrate= 263.2kbits/s dup=0 drop=226
frame=   85 fps= 15 q=26.0 size=      84kB time=00:00:02.66 bitrate= 259.3kbits/s dup=0 drop=249
frame=   93 fps= 15 q=28.0 size=     115kB time=00:00:03.20 bitrate= 295.2kbits/s dup=0 drop=271
frame=  100 fps= 15 q=26.0 size=     124kB time=00:00:03.66 bitrate= 276.9kbits/s dup=0 drop=294
frame=  108 fps= 15 q=29.0 size=     168kB time=00:00:04.20 bitrate= 328.5kbits/s dup=0 drop=316
frame=  116 fps= 15 q=29.0 size=     188kB time=00:00:04.73 bitrate= 325.5kbits/s dup=0 drop=340
frame=  123 fps= 15 q=29.0 size=     205kB time=00:00:05.20 bitrate= 323.2kbits/s dup=0 drop=363
frame=  131 fps= 15 q=30.0 size=     231kB time=00:00:05.73 bitrate= 330.5kbits/s dup=0 drop=385
Que input is backward in time
[flv @ 0x10180ee00] Audio timestamp 8837 < 8847 invalid, cliping
frame=  135 fps= 15 q=0.0 Lsize=     318kB time=00:00:08.87 bitrate= 293.8kbits/s dup=0 drop=399    
video:239kB audio:69kB global headers:0kB muxing overhead 3.045006%
[libx264 @ 0x10180f400] frame I:4     Avg QP:25.14  size: 14914
[libx264 @ 0x10180f400] frame P:131   Avg QP:27.29  size:  1412
[libx264 @ 0x10180f400] mb I  I16..4:  3.5%  0.0% 96.5%
[libx264 @ 0x10180f400] mb P  I16..4:  0.2%  0.0%  4.3%  P16..4: 19.8%  7.5%  3.5%  0.0%  0.0%    skip:64.7%
[libx264 @ 0x10180f400] final ratefactor: 23.29
[libx264 @ 0x10180f400] coded y,uvDC,uvAC intra: 94.7% 91.3% 70.7% inter: 12.6% 10.4% 1.3%
[libx264 @ 0x10180f400] i16 v,h,dc,p:  7% 55% 10% 28%
[libx264 @ 0x10180f400] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 23% 22%  9%  6%  7%  9%  7%  8%  8%
[libx264 @ 0x10180f400] i8c dc,h,v,p: 49% 20% 24%  7%
[libx264 @ 0x10180f400] ref P L0: 85.8%  8.0%  6.2%
[libx264 @ 0x10180f400] kb/s:217.41
Received signal 15: terminating.

I observe the same (correct) behavior when I shoot straight flv as well.

Please let me know if I've not included everything necessary.

Thanks!

Change History (6)

comment:1 by Michael Smithng, 12 years ago

I compiled the latest version from the git repo last night, because I told Carl I would try.

ffmpeg version N-41668-g564bb24 Copyright (c) 2000-2012 the FFmpeg developers
  built on Jun 17 2012 20:45:55 with gcc 4.2.1 (Apple Inc. build 5666) (dot 3)
  configuration: --logfile=./config_64.log --disable-ffplay --enable-gpl --enable-nonfree --enable-libx264 --enable-libfaac --enable-libmp3lame --arch=x86_64
  libavutil      51. 58.100 / 51. 58.100
  libavcodec     54. 25.100 / 54. 25.100
  libavformat    54.  6.101 / 54.  6.101
  libavdevice    54.  0.100 / 54.  0.100
  libavfilter     2. 81.100 /  2. 81.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 15.100 /  0. 15.100
  libpostproc    52.  0.100 / 52.  0.100
[dv @ 0x10180e800] Estimating duration from bitrate, this may be inaccurate
Guessed Channel Layout for  Input Stream #0.1 : stereo
Input #0, dv, from '$SOURCE':
  Duration: N/A, start: 0.000000, bitrate: 28771 kb/s
    Stream #0:0: Video: dvvideo, yuv411p, 720x480 [SAR 8:9 DAR 4:3], 28771 kb/s, 29.97 tbr, 29.97 tbn, 29.97 tbc
    Stream #0:1: Audio: pcm_s16le, 48000 Hz, stereo, s16, 1536 kb/s
[Parsed_yadif_0 @ 0x101212140] mode:1 parity:1 auto_enable:0
[buffer @ 0x101213460] w:720 h:480 pixfmt:yuv411p tb:1001/30000 fr:30000/1001 sar:8/9 sws_param:flags=2
[ffmpeg_buffersink @ 0x1012136c0] No opaque field provided
[scale @ 0x101213920] w:720 h:480 fmt:yuv411p sar:8/9 -> w:320 h:240 fmt:yuv420p sar:1/1 flags:0x4
[aformat @ 0x10121f3e0] auto-inserting filter 'auto-inserted resampler 0' between the filter 'Parsed_anull_0' and the filter 'aformat'
[auto-inserted resampler 0 @ 0x10121faa0] chl:stereo fmt:s16 r:48000Hz -> chl:stereo fmt:s16 r:44100Hz
[libx264 @ 0x10180f400] using SAR=1/1
[libx264 @ 0x10180f400] using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.1 Cache64
[libx264 @ 0x10180f400] profile Constrained Baseline, level 3.0
[libx264 @ 0x10180f400] 264 - core 125 - H.264/MPEG-4 AVC codec - Copyleft 2003-2012 - http://www.videolan.org/x264.html - options: cabac=0 ref=3 deblock=1:0:0 analyse=0x1:0x111 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=4 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=0 keyint=45 keyint_min=23 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=abr mbtOutput #0, rtsp, to 'rtsp://[...]':
  Metadata:
    encoder         : Lavf54.6.101
    Stream #0:0: Video: h264, yuv420p, 320x240 [SAR 1:1 DAR 4:3], q=-1--1, 240 kb/s, 90k tbn, 15 tbc
    Stream #0:1: Audio: aac, 44100 Hz, stereo, s16, 64 kb/s
Stream mapping:
  Stream #0:0 -> #0:0 (dvvideo -> libx264)
  Stream #0:1 -> #0:1 (pcm_s16le -> libfaac)
Press [q] to stop, [?] for help
frame=   48 fps= 16 q=32.0 size=       0kB time=00:00:00.20 bitrate=   0.0kbits/s dup=0 drop=134
frame=   56 fps= 16 q=33.0 size=       0kB time=00:00:00.73 bitrate=   0.0kbits/s dup=0 drop=156
frame=   63 fps= 16 q=30.0 size=       0kB time=00:00:01.20 bitrate=   0.0kbits/s dup=0 drop=179
frame=   71 fps= 16 q=30.0 size=       0kB time=00:00:01.73 bitrate=   0.0kbits/s dup=0 drop=209
frame=   79 fps= 16 q=32.0 size=       0kB time=00:00:02.26 bitrate=   0.0kbits/s dup=0 drop=225
frame=   86 fps= 15 q=32.0 size=       0kB time=00:00:02.73 bitrate=   0.0kbits/s dup=0 drop=248
frame=   94 fps= 15 q=30.0 size=       0kB time=00:00:03.26 bitrate=   0.0kbits/s dup=0 drop=270
frame=  102 fps= 15 q=29.0 size=       0kB time=00:00:03.80 bitrate=   0.0kbits/s dup=0 drop=294
frame=  109 fps= 15 q=28.0 size=       0kB time=00:00:04.26 bitrate=   0.0kbits/s dup=0 drop=315
frame=  117 fps= 15 q=27.0 size=       0kB time=00:00:04.80 bitrate=   0.0kbits/s dup=0 drop=339
frame=  117 fps= 15 q=0.0 Lsize=       0kB time=00:00:07.61 bitrate=   0.0kbits/s dup=0 drop=341    
video:241kB audio:60kB global headers:0kB muxing overhead -100.000000%
[libx264 @ 0x10180f400] frame I:7     Avg QP:26.30  size:  4395
[libx264 @ 0x10180f400] frame P:110   Avg QP:28.08  size:  1955
[libx264 @ 0x10180f400] mb I  I16..4: 43.1%  0.0% 56.9%
[libx264 @ 0x10180f400] mb P  I16..4: 10.6%  0.0% 16.2%  P16..4: 29.7% 10.9%  3.3%  0.0%  0.0%    skip:29.3%
[libx264 @ 0x10180f400] final ratefactor: 25.93
[libx264 @ 0x10180f400] coded y,uvDC,uvAC intra: 49.6% 62.8% 31.1% inter: 16.2% 24.3% 1.6%
[libx264 @ 0x10180f400] i16 v,h,dc,p: 44% 34%  9% 13%
[libx264 @ 0x10180f400] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 30% 24% 15%  5%  7%  6%  5%  6%  4%
[libx264 @ 0x10180f400] i8c dc,h,v,p: 55% 17% 23%  6%
[libx264 @ 0x10180f400] ref P L0: 74.6% 13.9% 11.5%
[libx264 @ 0x10180f400] kb/s:252.09
Received signal 15: terminating.

Still working with RTMP:

ffmpeg version N-41668-g564bb24 Copyright (c) 2000-2012 the FFmpeg developers
  built on Jun 17 2012 20:45:55 with gcc 4.2.1 (Apple Inc. build 5666) (dot 3)
  configuration: --logfile=./config_64.log --disable-ffplay --enable-gpl --enable-nonfree --enable-libx264 --enable-libfaac --enable-libmp3lame --arch=x86_64
  libavutil      51. 58.100 / 51. 58.100
  libavcodec     54. 25.100 / 54. 25.100
  libavformat    54.  6.101 / 54.  6.101
  libavdevice    54.  0.100 / 54.  0.100
  libavfilter     2. 81.100 /  2. 81.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 15.100 /  0. 15.100
  libpostproc    52.  0.100 / 52.  0.100
[dv @ 0x10180e800] Estimating duration from bitrate, this may be inaccurate
Guessed Channel Layout for  Input Stream #0.1 : stereo
Input #0, dv, from '$SOURCE':
  Duration: N/A, start: 0.000000, bitrate: 28771 kb/s
    Stream #0:0: Video: dvvideo, yuv411p, 720x480 [SAR 8:9 DAR 4:3], 28771 kb/s, 29.97 tbr, 29.97 tbn, 29.97 tbc
    Stream #0:1: Audio: pcm_s16le, 48000 Hz, stereo, s16, 1536 kb/s
[Parsed_yadif_0 @ 0x101214220] mode:1 parity:1 auto_enable:0
[buffer @ 0x1012120c0] w:720 h:480 pixfmt:yuv411p tb:1001/30000 fr:30000/1001 sar:8/9 sws_param:flags=2
[ffmpeg_buffersink @ 0x1012126a0] No opaque field provided
[scale @ 0x101214a40] w:720 h:480 fmt:yuv411p sar:8/9 -> w:320 h:240 fmt:yuv420p sar:1/1 flags:0x4
[aformat @ 0x101220420] auto-inserting filter 'auto-inserted resampler 0' between the filter 'Parsed_anull_0' and the filter 'aformat'
[auto-inserted resampler 0 @ 0x101220a40] chl:stereo fmt:s16 r:48000Hz -> chl:stereo fmt:s16 r:44100Hz
[libx264 @ 0x10180f400] using SAR=1/1
[libx264 @ 0x10180f400] using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle SSE4.1 Cache64
[libx264 @ 0x10180f400] profile Constrained Baseline, level 3.0
[libx264 @ 0x10180f400] 264 - core 125 - H.264/MPEG-4 AVC codec - Copyleft 2003-2012 - http://www.videolan.org/x264.html - options: cabac=0 ref=3 deblock=1:0:0 analyse=0x1:0x111 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=4 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=0 keyint=45 keyint_min=23 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=abr mbtOutput #0, flv, to 'rtmp://[...]':
  Metadata:
    encoder         : Lavf54.6.101
    Stream #0:0: Video: h264 ([7][0][0][0] / 0x0007), yuv420p, 320x240 [SAR 1:1 DAR 4:3], q=-1--1, 240 kb/s, 1k tbn, 15 tbc
    Stream #0:1: Audio: aac ([10][0][0][0] / 0x000A), 44100 Hz, stereo, s16, 64 kb/s
Stream mapping:
  Stream #0:0 -> #0:0 (dvvideo -> libx264)
  Stream #0:1 -> #0:1 (pcm_s16le -> libfaac)
Press [q] to stop, [?] for help
frame=   47 fps= 15 q=33.0 size=       7kB time=00:00:00.13 bitrate= 426.0kbits/s dup=0 drop=135
frame=   55 fps= 15 q=32.0 size=      30kB time=00:00:00.66 bitrate= 369.7kbits/s dup=0 drop=157
frame=   63 fps= 16 q=29.0 size=      46kB time=00:00:01.20 bitrate= 316.7kbits/s dup=0 drop=181
frame=   70 fps= 15 q=31.0 size=      63kB time=00:00:01.66 bitrate= 311.8kbits/s dup=0 drop=204
frame=   78 fps= 15 q=31.0 size=      85kB time=00:00:02.20 bitrate= 315.3kbits/s dup=0 drop=226
video:311kB audio:85kB global headers:0kB muxing overhead 2.864342%
[libx264 @ 0x10180f400] frame I:8     Avg QP:26.99  size:  5575
[libx264 @ 0x10180f400] frame P:156   Avg QP:29.46  size:  1753
[libx264 @ 0x10180f400] mb I  I16..4: 30.2%  0.0% 69.8%
[libx264 @ 0x10180f400] mb P  I16..4:  7.4%  0.0%  7.5%  P16..4: 37.9% 18.2%  5.1%  0.0%  0.0%    skip:23.8%
[libx264 @ 0x10180f400] final ratefactor: 26.13
[libx264 @ 0x10180f400] coded y,uvDC,uvAC intra: 48.6% 63.9% 20.4% inter: 25.1% 21.3% 0.3%
[libx264 @ 0x10180f400] i16 v,h,dc,p: 31% 38%  8% 23%
[libx264 @ 0x10180f400] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 27% 26% 15%  5%  6%  6%  6%  4%  5%
[libx264 @ 0x10180f400] i8c dc,h,v,p: 52% 20% 22%  7%
[libx264 @ 0x10180f400] ref P L0: 89.0%  7.0%  4.0%
[libx264 @ 0x10180f400] kb/s:232.76
Received signal 15: terminating.

comment:2 by Michael Smithng, 12 years ago

could this possibly be an issue with x264?

comment:3 by Michael Niedermayer, 12 years ago

Cc: Michael Niedermayer added

iam happy to look into this and fix it but how do i reproduce it ? is a account on wowza.server.com needed or can it be reproduced without this? maybe some vlc/ffmpeg/whatever commands i can copy and paste to reproduce it ? I suspect fixing this if i can reproduce it would take me 5min but figuring out how to reproduce it well i dunno where to start :)

comment:4 by Michael Smithng, 12 years ago

Thanks.

I actually have a couple patches for ffmpeg.c and libavformat/utils.c that I need to submit for review.

These produce accurate output data for each non-seekable output stream (there was a FIXME in ffmpeg.c: 'print_report' to address this...). Additionally it accurately tracks the amount of kBytes that have been shipped since the encode started.

example output:

frame=  991 fps= 30 q=24.0 kB=  2299.2 kbps= 571.6 size=       0kB time=00:00:31.86 bitrate=   0.0kbits/s dup=1 drop=0
frame= 1021 fps= 30 q=24.0 kB=  2369.8 kbps= 564.8 size=       0kB time=00:00:32.86 bitrate=   0.0kbits/s dup=1 drop=0
frame= 1051 fps= 30 q=24.0 kB=  2438.7 kbps= 551.5 size=       0kB time=00:00:33.86 bitrate=   0.0kbits/s dup=1 drop=0
frame= 1081 fps= 30 q=24.0 kB=  2504.6 kbps= 527.1 size=       0kB time=00:00:34.86 bitrate=   0.0kbits/s dup=1 drop=0
frame= 1111 fps= 30 q=24.0 kB=  2574.6 kbps= 559.9 size=       0kB time=00:00:35.86 bitrate=   0.0kbits/s dup=1 drop=0

Granted, my interests lie in non-seekable output as I'm using this to stream live video. If there's a procedure that I need to follow to ensure that things work as expected for alternate outputs, please advise.

I'll be honest, I'm not sure how well these additional fields are going to be received. We didn't want to mess with the bitrate entry since I figured others were probably using mechanisms that expected that to be there.

I'll try to rebase tomorrow morning first thing and get these changes in for review.

Judging by the above, do you have any comments that can be shared with me now?

comment:5 by Michael Smithng, 12 years ago

It turns out, that bitrate on a non-seekable stream eventually ends up as a long running average if the stream is up for extended periods of time. No amount of scene change triggered any variance in streams that were up for instances running 5+ days...

in reply to:  3 comment:6 by Michael Smithng, 12 years ago

Replying to michael:

iam happy to look into this and fix it but how do i reproduce it ? is a account on wowza.server.com needed or can it be reproduced without this?

I would think that a simple output to the local host via rtsp would exhibit the same behavior. I'll admit, I haven't had time to try. I'll see if I can get some details on that today. I'm hoping to have the patch submitted before that though. I have to review the latest HEAD as my rebase yesterday had some conflicts so we need to figure out what failed on the rebase first.

maybe some vlc/ffmpeg/whatever commands i can copy and paste to reproduce it ?

This was all local client centric. I would imagine if you used the same command I posted in the ticket (with a local file as input) and output to a localhost rtsp port... you should see the same results in your terminal or wherever you're landing the output log via stderr.

I suspect fixing this if i can reproduce it would take me 5min but figuring out how to reproduce it well i dunno where to start :)

I can appreciate that. Let me know if anything in my above comments doesn't jive and we can sync up on getting it reproduced.

Again, I'm trying to get a patch submitted (I've just not had time to get it sent :( ) to solve this as well. It's tested and reports the output above. If anyone sees any problems with this please let me know.

Note: See TracTickets for help on using tickets.