使用ffmpeg支持ICY元数据 [英] ICY metadata support with ffmpeg
问题描述
一种方法是自己处理连接/流,并将自定义IOStream发送到ffmpeg。
还有其他简单的方法吗?或者分解者可用?
谢谢
补丁在此支持: http://web.archiveorange.com/archive/v/yR2T400567mWEyyZHg3k
但是,它看起来不像它那样。我建议你自己解析一下。请参阅我的答案:
https:// stackoverflow .com / a / 4914538/362536
或者,您只需访问 /7.html
在SHOUTcast服务器上,您将得到如下一行:
1,1,15,625,1,128,呵呵 - 请留下
字段是:
- 听众数量
- 流状态(1表示你在空中,0表示来源不在)
- 此服务器侦听器的峰值数量运行
- 服务器配置允许的同时侦听器的最大数量
- 侦听器的唯一数量,基于IP
- 当前比特率(千比特)
- 标题。 (请注意,即使您的标题中有逗号,也不会转义任何内容。)
请注意, /7.html
并不总是在非SHOUTcast服务器上可用,并且在新版本的测试版中可能不可用。虽然这是一种快捷方便的方法,但您最好分析发送给客户端的元数据。
Is there any way to get ICY metadata from shoutcast stream using FFMpeg ? One way would be to deal with the connection/stream by myself and send Custom IOStream to ffmpeg.
Is there any other simple way? or demuxer available ?
Thanks
There was discussion of a patch for supporting it here: http://web.archiveorange.com/archive/v/yR2T400567mWEyyZHg3k
But, it doesn't look like it made it in yet. I suggest you simply parse this out yourself. See my answer here for how to do this:
https://stackoverflow.com/a/4914538/362536
Alternatively, you can just access /7.html
on SHOUTcast servers, and you will get a line like this:
1,1,15,625,1,128,Oh Mercy - Stay, Please Stay
The fields are:
- Number of listeners
- Stream status (1 means you're on the air, 0 means the source isn't there)
- Peak number of listeners for this server run
- Max number of simultaneous listeners the server is configured to allow
- The unique number of listeners, based on IP
- Current bitrate in kilobits
- The title. (Note, even if you have a comma in your title, it isn't escaped or anything.)
Beware though that /7.html
isn't always available on non-SHOUTcast servers, and may not be available in the beta of the new version. While this is a quick and easy method, you would be better off parsing the metadata sent to clients.
这篇关于使用ffmpeg支持ICY元数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!