[FFmpeg-trac] #4566(ffmpeg:new): ffmpeg won't copy metadata ("StreamTitle") from audio live stream (transcoding)
FFmpeg
trac at avcodec.org
Tue May 19 03:52:04 CEST 2015
#4566: ffmpeg won't copy metadata ("StreamTitle") from audio live stream
(transcoding)
----------------------------------+-------------------------------------
Reporter: easydoor | Type: defect
Status: new | Priority: important
Component: ffmpeg | Version: 2.6.2
Keywords: metadata | Blocked By:
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
----------------------------------+-------------------------------------
It won't copy "StreamTitle" from input to output while transcoding input
from mp3 to aac.
I'm using version v2.6.1 compiled by me on ubuntu 14.
I try simpliest transcoding with -c:a copy option and sending it to
icecast v2.4.1 and as a client I'm using latest winamp and vlc.
In booth player as title is showing only the mount point (in this case
mystream) from icecast:
{{{
icecast://source:mypass@x.x.x.x:8000/mystream
}}}
and not the StreamTitle from input file.
Why and how can I just pass it from input to output?
I don't think that problem is Icecast, because I try to stream with SAM
Broadcaster and in Winamp I see updated StreamTitle in real time.
Here is the command line:
{{{
/root/ffmpeg_sources/ffmpeg*/./ffmpeg -stats -report -i
http://streaming.streamonomy.com/ElectricFM -c:a copy -content_type
audio/mpeg -f mp3 icecast://source:mypass@x.x.x.x:8000/mystream
}}}
and here is the output:
{{{
root at vs4063:~# /root/ffmpeg_sources/ffmpeg*/./ffmpeg -stats -report -i
http://streaming.streamonomy.com/ElectricFM -c:a copy -content_type
audio/mpeg -f mp3 icecast://source:mypass@x.x.x.x:8000/mystream
ffmpeg started on 2015-03-23 at 03:01:01
Report written to "ffmpeg-20150323-030101.log"
ffmpeg version 2.6.1 Copyright (c) 2000-2015 the FFmpeg developers
built with gcc 4.8 (Ubuntu 4.8.2-19ubuntu1)
configuration: --prefix=/root/ffmpeg_build --extra-
cflags=-I/root/ffmpeg_build/include --extra-
ldflags=-L/root/ffmpeg_build/lib --bindir=/root/bin --enable-gpl --enable-
libass --enable-libfdk-aac --enable-libfaac --enable-libfreetype --enable-
libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis
--enable-libvpx --enable-libx264 --enable-libaacplus --enable-nonfree
libavutil 54. 20.100 / 54. 20.100
libavcodec 56. 26.100 / 56. 26.100
libavformat 56. 25.101 / 56. 25.101
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 11.102 / 5. 11.102
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 1.100 / 1. 1.100
libpostproc 53. 3.100 / 53. 3.100
Input #0, mp3, from 'http://streaming.streamonomy.com/ElectricFM':
Metadata:
icy-br : 128
icy-description : ElectricFM plays today's dance hits!
icy-genre : Electronic Dance Pop
icy-name : ElectricFM.com - America's Real Dance!
icy-pub : 1
icy-url : http://www.electricfm.com
StreamTitle : KYGO f/ CONRAD - FIRESTONE
Duration: N/A, start: 0.000000, bitrate: 128 kb/s
Stream #0:0: Audio: mp3, 44100 Hz, stereo, s16p, 128 kb/s
Output #0, mp3, to 'icecast://source:mypass@x.x.x.x:8000/mystream':
Metadata:
icy-br : 128
icy-description : ElectricFM plays today's dance hits!
icy-genre : Electronic Dance Pop
icy-name : ElectricFM.com - America's Real Dance!
icy-pub : 1
icy-url : http://www.electricfm.com
StreamTitle : KYGO f/ CONRAD - FIRESTONE
TSSE : Lavf56.25.101
Stream #0:0: Audio: mp3, 44100 Hz, stereo, 128 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Press [q] to stop, [?] for help
size= 2093kB time=00:02:13.95 bitrate= 128.0kbits/s
video:0kB audio:2093kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: 0.016237%
}}}
[[Image(http://ffmpeg.gusari.org/download/file.php?id=103)]]
In winamp first track is original and second transcoded..
Here is with debug:
{{{
/root/ffmpeg_sources/ffmpeg*/./ffmpeg -stats -v 512 -report -i
http://streaming.streamonomy.com/ElectricFM -c:a copy -content_type
audio/mpeg -f mp3 icecast://source:mypass@x.x.x.x:8000/mystream/mystream
ffmpeg started on 2015-03-23 at 03:51:36
Report written to "ffmpeg-20150323-035136.log"
ffmpeg version 2.6.1 Copyright (c) 2000-2015 the FFmpeg developers
built with gcc 4.8 (Ubuntu 4.8.2-19ubuntu1)
configuration: --prefix=/root/ffmpeg_build --extra-
cflags=-I/root/ffmpeg_build/include --extra-
ldflags=-L/root/ffmpeg_build/lib --bindir=/root/bin --enable-gpl --enable-
libass --enable-libfdk-aac --enable-libfaac --enable-libfreetype --enable-
libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis
--enable-libvpx --enable-libx264 --enable-libaacplus --enable-nonfree
libavutil 54. 20.100 / 54. 20.100
libavcodec 56. 26.100 / 56. 26.100
libavformat 56. 25.101 / 56. 25.101
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 11.102 / 5. 11.102
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 1.100 / 1. 1.100
libpostproc 53. 3.100 / 53. 3.100
Splitting the commandline.
Reading option '-stats' ... matched as option 'stats' (print progress
report during encoding) with argument '1'.
Reading option '-v' ... matched as option 'v' (set logging level) with
argument '512'.
Reading option '-report' ... matched as option 'report' (generate a
report) with argument '1'.
Reading option '-i' ... matched as input file with argument
'http://streaming.streamonomy.com/ElectricFM'.
Reading option '-c:a' ... matched as option 'c' (codec name) with
argument 'copy'.
Reading option '-content_type' ... matched as AVOption 'content_type'
with argument 'audio/mpeg'.
Reading option '-f' ... matched as option 'f' (force format) with
argument 'mp3'.
Reading option 'icecast://source:mypass@x.x.x.x:8000/mystream' ...
matched as output file.
Finished splitting the commandline.
Parsing a group of options: global .
Applying option stats (print progress report during encoding) with
argument 1.
Applying option v (set logging level) with argument 512.
Applying option report (generate a report) with argument 1.
Successfully parsed a group of options.
Parsing a group of options: input file
http://streaming.streamonomy.com/ElectricFM.
Successfully parsed a group of options.
Opening an input file: http://streaming.streamonomy.com/ElectricFM.
[http @ 0x217cf80] request: GET /ElectricFM HTTP/1.1
User-Agent: Lavf/56.25.101
Accept: */*
Range: bytes=0-
Connection: close
Host: streaming.streamonomy.com
Icy-MetaData: 1
[http @ 0x217cf80] header='HTTP/1.0 200 OK'
[http @ 0x217cf80] http_code=200
[http @ 0x217cf80] header='Accept-Ranges: none'
[http @ 0x217cf80] header='Content-Type: audio/mpeg'
[http @ 0x217cf80] header='icy-br:128'
[http @ 0x217cf80] header='ice-audio-info: ice-samplerate=44100;ice-
bitrate=128;ice-channels=2'
[http @ 0x217cf80] header='icy-br:128'
[http @ 0x217cf80] header='icy-description:ElectricFM plays today's
dance hits!'
[http @ 0x217cf80] header='icy-genre:Electronic Dance Pop'
[http @ 0x217cf80] header='icy-name:ElectricFM.com - America's Real
Dance!'
[http @ 0x217cf80] header='icy-pub:1'
[http @ 0x217cf80] header='icy-url:http://www.electricfm.com'
[http @ 0x217cf80] header='Server: Icecast 2.3.3-kh8'
[http @ 0x217cf80] header='Cache-Control: no-cache, no-store'
[http @ 0x217cf80] header='Pragma: no-cache'
[http @ 0x217cf80] header='Access-Control-Allow-Origin: *'
[http @ 0x217cf80] header='Access-Control-Allow-Headers: Origin,
Accept, X-Requested-With, Content-Type'
[http @ 0x217cf80] header='Access-Control-Allow-Methods: GET, OPTIONS,
HEAD'
[http @ 0x217cf80] header='Connection: close'
[http @ 0x217cf80] header='Expires: Mon, 26 Jul 1997 05:00:00 GMT'
[http @ 0x217cf80] header='icy-metaint:16000'
[http @ 0x217cf80] header=''
[mp3 @ 0x217daa0] Format mp3 probed with size=2048 and score=51
[mp3 @ 0x217daa0] Before avformat_find_stream_info() pos: 0 bytes
read:2508 seeks:0
[mp3 @ 0x217daa0] All info found
[mp3 @ 0x217daa0] After avformat_find_stream_info() pos: 21504 bytes
read:23824 seeks:0 frames:50
Input #0, mp3, from 'http://streaming.streamonomy.com/ElectricFM':
Metadata:
icy-br : 128
icy-description : ElectricFM plays today's dance hits!
icy-genre : Electronic Dance Pop
icy-name : ElectricFM.com - America's Real Dance!
icy-pub : 1
icy-url : http://www.electricfm.com
StreamTitle : PAUL OAKENFOLD and DISFUNKTION f/ SPITFIRE -
BEAUTIFUL WORLD
Duration: N/A, start: 0.000000, bitrate: 128 kb/s
Stream #0:0, 50, 1/14112000: Audio: mp3, 44100 Hz, stereo, s16p,
128 kb/s
Successfully opened the file.
Parsing a group of options: output file
icecast://source:mypass@x.x.x.x:8000/mystream.
Applying option c:a (codec name) with argument copy.
Applying option f (force format) with argument mp3.
Successfully parsed a group of options.
Opening an output file: icecast://source:mypass@x.x.x.x:8000/mystream.
[http @ 0x2191520] request: PUT /mystream HTTP/1.1
User-Agent: Lavf/56.25.101
Accept: */*
Expect: 100-continue
Connection: close
Host: x.x.x.x:8000
Content-Type: audio/mpeg
Icy-MetaData: 1
Ice-Public: 0
Authorization: Basic c291cmNlOnNpbnVzZm04MA==
[http @ 0x2191520] header='HTTP/1.1 100 Continue'
[http @ 0x2191520] http_code=100
[http @ 0x2191520] header=''
Successfully opened the file.
Output #0, mp3, to 'icecast://source:mypass@x.x.x.x:8000/mystream5.3':
Metadata:
icy-br : 128
icy-description : ElectricFM plays today's dance hits!
icy-genre : Electronic Dance Pop
icy-name : ElectricFM.com - America's Real Dance!
icy-pub : 1
icy-url : http://www.electricfm.com
StreamTitle : PAUL OAKENFOLD and DISFUNKTION f/ SPITFIRE -
BEAUTIFUL WORLD
TSSE : Lavf56.25.101
Stream #0:0, 0, 1/14112000: Audio: mp3, 44100 Hz, stereo, 128 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Press [q] to stop, [?] for help
size= 101kB time=00:00:06.42 bitrate= 128.5kbits/s
video:0kB audio:100kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: 0.371530%
Input file #0 (http://streaming.streamonomy.com/ElectricFM):
Input stream #0:0 (audio): 246 packets read (102818 bytes);
Total: 246 packets (102818 bytes) demuxed
Output file #0 (icecast://source:mypass@x.x.x.x:8000/mystream):
Output stream #0:0 (audio): 246 packets muxed (102818 bytes);
Total: 246 packets (102818 bytes) muxed
0 frames successfully decoded, 0 decoding errors
[AVIOContext @ 0x2192e80] Statistics: 0 seeks, 247 writeouts
[AVIOContext @ 0x21884c0] Statistics: 105326 bytes read, 0 seeks
}}}
The main usage of transcoding would be:
{{{
/root/ffmpeg_sources/ffmpeg/./ffmpeg -stats -v 1024 -report -i
http://stream2.electricfm.com -acodec libaacplus -ar 44.1k -ab 40k -ac 2
-content_type audio/aacp -f adts
icecast://source:mypass@x.x.x.x:8000/electricfm@40k -acodec libaacplus -ar
44.1k -ab 64k -ac 2 -content_type audio/aacp -f adts
icecast://source:mypass@x.x.x.x:8000/electricfm@64k < /dev/null >/dev/null
2>/var/log/ffmpeg.log &
}}}
but it gave me same result..not showing "StreamTitle" from input to
output!
I try with options -map_metada 0:s:0 and others option, but without
success.
--
Ticket URL: <https://trac.ffmpeg.org/ticket/4566>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list