[FFmpeg-trac] #4145(undetermined:new): when rebroadcasting/streaming to flv format with aac_adtstoasc bitstream filter, sound gets removed

FFmpeg trac at avcodec.org
Mon Dec 1 19:11:18 CET 2014


#4145: when rebroadcasting/streaming to flv format with aac_adtstoasc bitstream
filter, sound gets removed
-------------------------------------+-------------------------------------
             Reporter:  PyroDevil    |                    Owner:
                 Type:  defect       |                   Status:  new
             Priority:  normal       |                Component:
              Version:  git-master   |  undetermined
             Keywords:               |               Resolution:
             Blocking:               |               Blocked By:
Analyzed by developer:  0            |  Reproduced by developer:  0
-------------------------------------+-------------------------------------

Comment (by PyroDevil):

 So I now have setup a local nginx server to receive the stream instead of
 twitch. On this server it works. Apparently it has something to do with
 the implementation of the communication between ffmpeg and the twitch
 servers.

 Here is the streaming log:
 {{{
 % livestreamer -O www.twitch.tv/otherstream worst 2>/dev/null | ffmpeg -i
 - -c copy -bsf:a aac_adtstoasc -f flv "rtmp://localhost/live/test"
 ffmpeg version N-68130-gb50e003 Copyright (c) 2000-2014 the FFmpeg
 developers
   built on Dec  1 2014 14:44:49 with gcc 4.9.2 (GCC)
   configuration: --prefix=/usr --disable-static --enable-gpl --enable-
 libass --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame
 --enable-libopus --enable-libtheora --enable-libvorbis --enable-libvpx
 --enable-libx264 --enable-libx265 --enable-nonfree --enable-shared
 --enable-x11grab
   libavutil      54. 15.100 / 54. 15.100
   libavcodec     56. 13.100 / 56. 13.100
   libavformat    56. 15.101 / 56. 15.101
   libavdevice    56.  3.100 / 56.  3.100
   libavfilter     5.  2.103 /  5.  2.103
   libswscale      3.  1.101 /  3.  1.101
   libswresample   1.  1.100 /  1.  1.100
   libpostproc    53.  3.100 / 53.  3.100
 Input #0, mpegts, from 'pipe:':
   Duration: N/A, start: 63896.314000, bitrate: 136 kb/s
   Program 1
     Stream #0:0[0x100]: Audio: aac (LC) ([15][0][0][0] / 0x000F), 44100
 Hz, stereo, fltp, 136 kb/s
     Stream #0:1[0x101]: Video: h264 (Constrained Baseline) ([27][0][0][0]
 / 0x001B), yuv420p, 400x226, 20 fps, 20 tbr, 90k tbn, 2k tbc
     Stream #0:2[0x102]: Data: timed_id3 (ID3  / 0x20334449)
 [tcp @ 0x1480700] Connection to tcp://localhost:1935 failed (Connection
 refused), trying next address
 Output #0, flv, to 'rtmp://localhost/live/test':
   Metadata:
     encoder         : Lavf56.15.101
     Stream #0:0: Video: h264 ([7][0][0][0] / 0x0007), yuv420p, 400x226,
 q=2-31, 20 fps, 1k tbn, 90k tbc
     Stream #0:1: Audio: aac ([10][0][0][0] / 0x000A), 44100 Hz, stereo,
 136 kb/s
 Stream mapping:
   Stream #0:1 -> #0:0 (copy)
   Stream #0:0 -> #0:1 (copy)
 frame=  118 fps= 42 q=-1.0 size=     150kB time=00:00:06.06 bitrate=
 202.4kbits/s
 frame=  198 fps= 33 q=-1.0 size=     246kB time=00:00:10.05 bitrate=
 200.1kbits/s
 frame=  278 fps= 31 q=-1.0 size=     344kB time=00:00:14.04 bitrate=
 200.6kbits/s
 frame=  358 fps= 26 q=-1.0 size=     438kB time=00:00:18.04 bitrate=
 199.1kbits/s
 frame=  438 fps= 26 q=-1.0 size=     537kB time=00:00:22.05 bitrate=
 199.3kbits/s
 frame=  478 fps= 24 q=-1.0 size=     585kB time=00:00:24.05 bitrate=
 199.3kbits/s
 frame=  558 fps= 24 q=-1.0 size=     682kB time=00:00:28.05 bitrate=
 199.1kbits/s
 frame=  596 fps= 23 q=-1.0 size=     728kB time=00:00:29.90 bitrate=
 199.3kbits/s
 frame=  636 fps= 22 q=-1.0 size=     776kB time=00:00:31.95 bitrate=
 199.1kbits/s
 frame=  718 fps= 22 q=-1.0 size=     879kB time=00:00:36.06 bitrate=
 199.8kbits/s
 frame=  758 fps= 21 q=-1.0 size=     925kB time=00:00:37.98 bitrate=
 199.5kbits/s
 frame=  836 fps= 22 q=-1.0 size=    1022kB time=00:00:41.95 bitrate=
 199.6kbits/s
 frame=  878 fps= 21 q=-1.0 size=    1070kB time=00:00:43.97 bitrate=
 199.3kbits/s
 frame=  958 fps= 22 q=-1.0 size=    1170kB time=00:00:48.04 bitrate=
 199.5kbits/s
 frame=  998 fps= 21 q=-1.0 size=    1215kB time=00:00:49.96 bitrate=
 199.1kbits/s
 [flv @ 0x1421ea0] Failed to update header with correct duration.
 [flv @ 0x1421ea0] Failed to update header with correct filesize.
 frame= 1077 fps= 21 q=-1.0 Lsize=    1313kB time=00:00:53.98 bitrate=
 199.2kbits/s
 video:407kB audio:844kB subtitle:0kB other streams:0kB global headers:0kB
 muxing overhead: 4.967333%
 Received signal 2: terminating.
 }}}

 And here the receiving again:
 {{{
 % ffmpeg -i 'rtmp://localhost/live/test'
 ffmpeg version N-68130-gb50e003 Copyright (c) 2000-2014 the FFmpeg
 developers
   built on Dec  1 2014 14:44:49 with gcc 4.9.2 (GCC)
   configuration: --prefix=/usr --disable-static --enable-gpl --enable-
 libass --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame
 --enable-libopus --enable-libtheora --enable-libvorbis --enable-libvpx
 --enable-libx264 --enable-libx265 --enable-nonfree --enable-shared
 --enable-x11grab
   libavutil      54. 15.100 / 54. 15.100
   libavcodec     56. 13.100 / 56. 13.100
   libavformat    56. 15.101 / 56. 15.101
   libavdevice    56.  3.100 / 56.  3.100
   libavfilter     5.  2.103 /  5.  2.103
   libswscale      3.  1.101 /  3.  1.101
   libswresample   1.  1.100 /  1.  1.100
   libpostproc    53.  3.100 / 53.  3.100
 [tcp @ 0x1fe50c0] Connection to tcp://localhost:1935 failed (Connection
 refused), trying next address
 [flv @ 0x1fe6000] Stream discovered after head already parsed
     Last message repeated 1 times
 Input #0, flv, from 'rtmp://localhost/live/test':
   Metadata:
     Server          : NGINX RTMP (github.com/arut/nginx-rtmp-module)
     displayWidth    : 400
     displayHeight   : 226
     fps             : 20
     profile         :
     level           :
   Duration: 00:00:00.00, start: 23.893000, bitrate: N/A
     Stream #0:0: Audio: aac, 44100 Hz, stereo, fltp, 136 kb/s
     Stream #0:1: Data: none
     Stream #0:2: Video: h264 (Constrained Baseline), yuv420p, 400x226, 20
 fps, 20 tbr, 1k tbn, 2k tbc
 At least one output file must be specified
 }}}

 Now I am not sure how to proceed any further. Or have I tested it wrong by
 listening to the exact same rtmp address?

--
Ticket URL: <https://trac.ffmpeg.org/ticket/4145#comment:8>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list