Closed jimbo2018 closed 3 years ago
Yet another duplicate of https://github.com/ytdl-org/youtube-dl/issues/21302, by the same person... :angry: :-1: Both probably duplicates of still open https://github.com/ytdl-org/youtube-dl/issues/10787 (Support live streams in MPEG DASH) :wink: ...
@jimbo2018 :
Please, stop creating any additional duplicate issues on this...
"Your" bbc_radio_two_live
MPD isn't just special because it contains only audio segments (as you seem to suggest),
youtube-dl
does not (still) support Dynamic (live) MPEG-DASH manifests (MPD=Media Presentation Description), [generic]'s support is limited to Static ones (i.e. On-Demand streams).
I'm not saying it's impossible to implement via pure Python code, but I suspect it presents special challenges for the devs, given that the feature is still missing...
FWIW, youtube-dl
's [hlsnative] only supports On-Demand HLS playlists (M3U8), Live HLS streams are being delegated to FFmpeg... Perhaps something similar could be done for Dynamic MPDs, because, since a few years ago, FFmpeg itself has implemented MPD support for both Dynamic+Static MPDs :+1: ; the support is enabled if you build it with --enable-libxml2
(so that the XML parser is built), because MPDs are in fact a subset of XML files...
I must confess that MPD support in FFmpeg isn't yet fully ripe (especially where it comes to selecting the best quality variant by default), but most streams should download OK - of course, cenc (DRM) MPEG-DASH streams are unattainable...
As for recording the BBC Radio 2 Live (international) stream (over MPEG-DASH), a) it's rather unfortunate you (@jimbo2018) are still on Windows XP SP3, because there exists another widely known CLI Python application (specialising in Live streams) that does currently support dynamic MPDs, but that one demands at least py3.6, so that means Vista SP2 upwards... b) You can get yourself a fairly recent XP-compatible 32-bit build of FFmpeg with the DASH demuxer turned on (the one you're using is VERY old for the task... ) and then issue:
ffmpeg -v 32 -stats -re -i "http://a.files.bbci.co.uk/media/live/manifesto/audio/simulcast/dash/nonuk/dash_low/ak/bbc_radio_two.mpd" -vn -map 0:1 -c:a copy -movflags faststart "BBCr2live_dash_96k.m4a"
NB: Press q
when you wish to stop the recording;
-map 0:1
is needed to record the best variant (96kbps HE-AAC), because the worst variant (48kbps HE-AAC) is chosen by default... (:angry: :-1: )
ffmpeg version N-100546-g2c6f532-Reino Copyright (c) 2000-2021 the FFmpeg develo
pers
built with gcc 10.2.0 (GCC)
configuration: --arch=x86 --target-os=mingw32 --prefix=/cygdrive/m/ffmpeg-wind
ows-build-helpers-master/ffmpeg_local_builds/sandbox/cross_compilers/mingw-w64-i
686/i686-w64-mingw32 --cross-prefix=/cygdrive/m/ffmpeg-windows-build-helpers-mas
ter/ffmpeg_local_builds/sandbox/cross_compilers/mingw-w64-i686/bin/i686-w64-ming
w32- --extra-cflags='-march=pentium3 -mtune=athlon-xp -O2 -mfpmath=sse -msse' --
pkg-config=pkg-config --pkg-config-flags=--static --extra-version=Reino --enable
-gpl --enable-gray --enable-version3 --disable-debug --disable-doc --disable-htm
lpages --disable-manpages --disable-mediafoundation --disable-podpages --disable
-txtpages --disable-w32threads --enable-avisynth --enable-frei0r --enable-filter
=frei0r --enable-gmp --enable-libaom --enable-libass --enable-libfdk-aac --enabl
e-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --ena
ble-libgme --enable-libmp3lame --enable-libopenmpt --enable-libopus --enable-lib
soxr --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx
--enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-lib
xvid --enable-libzimg --enable-mbedtls
libavutil 56. 63.100 / 56. 63.100
libavcodec 58.115.102 / 58.115.102
libavformat 58. 65.100 / 58. 65.100
libavdevice 58. 11.103 / 58. 11.103
libavfilter 7. 95.100 / 7. 95.100
libswscale 5. 8.100 / 5. 8.100
libswresample 3. 8.100 / 3. 8.100
libpostproc 55. 8.100 / 55. 8.100
Input #0, dash, from 'http://a.files.bbci.co.uk/media/live/manifesto/audio/simul
cast/dash/nonuk/dash_low/ak/bbc_radio_two.mpd':
Duration: N/A, start: 1612143308.800000, bitrate: N/A
Program 0
Stream #0:0(en): Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo,
fltp (default)
Metadata:
variant_bitrate : 48000
id : audio=48000
Stream #0:1(en): Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo,
fltp (default)
Metadata:
variant_bitrate : 96000
id : audio=96000
Output #0, ipod, to 'BBCr2live_dash_96k.m4a':
Metadata:
encoder : Lavf58.65.100
Stream #0:0(en): Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo,
fltp (default)
Metadata:
variant_bitrate : 96000
id : audio=96000
Stream mapping:
Stream #0:1 -> #0:0 (copy)
Press [q] to stop, [?] for help
[dash @ 0037be00] No longer receiving stream_index 0/A
[ipod @ 06899fc0] Starting second pass: moving the moov atom to the beginning of
the file
size= 1079kB time=00:01:31.26 bitrate= 96.9kbits/s speed= 1x
video:0kB audio:1070kB subtitle:0kB other streams:0kB global headers:0kB muxing
overhead: 0.855490%
(I recorded just a 90s sample... ) Happy recordings... :smiley:
Thank you for that description. I also have Windows 7 on another machine, so will sort it on there. Thank you for the reply.
I do apologise as I was not aware that had already been answered hence I asked again.
Sorry for any inconvenience and thank you for the useful information.
Regards
James
On 01 February 2021 at 01:51 Vangelis66 notifications@github.com wrote:
Yet another duplicate of #21302 https://github.com/ytdl-org/youtube-dl/issues/21302 , by the same person... π π Both probably duplicates of still open #10787 https://github.com/ytdl-org/youtube-dl/issues/10787 (Support live streams in MPEG DASH) π ... @jimbo2018 https://github.com/jimbo2018 : Please, stop creating any additional duplicate issues on this... "Your" bbc_radio_two_live MPD isn't just special because it contains only audio segments (as you seem to suggest), youtube-dl does not (still) support Dynamic (live) MPEG-DASH manifests (MPD=Media Presentation Description), [generic]'s support is limited to Static ones (i.e. On-Demand streams). I'm not saying it's impossible to implement via pure Python code, but I suspect it presents special challenges for the devs, given that the feature is still missing... FWIW, youtube-dl's [hlsnative] only supports On-Demand HLS playlists (M3U8), Live HLS streams are being delegated to FFmpeg... Perhaps something similar could be done for Dynamic MPDs, because, since a few years ago, FFmpeg itself has implemented MPD support for both Dynamic+Static MPDs π ; the support is enabled if you build it with --enable-libxml2 (so that the XML parser is built), because MPDs are in fact a subset of XML files... I must confess that MPD support in FFmpeg isn't yet fully ripe (especially where it comes to selecting the best quality variant by default), but most streams should download OK - of course, cenc (DRM) MPEG-DASH streams are unattainable... As for recording the BBC Radio 2 Live (international) stream (over MPEG-DASH), a) it's rather unfortunate you (@jimbo2018 https://github.com/jimbo2018 ) are still on Windows XP SP3, because there exists another widely known CLI Python application (specialising in Live streams) that does currently support dynamic MPDs, but that one demands at least py3.6, so that means Vista SP2 upwards... b) You can get yourself a fairly recent XP-compatible 32-bit build of FFmpeg with the DASH demuxer turned on (the one you're using is VERY old for the task... ) and then issue: ffmpeg -v 32 -stats -re -i "http://a.files.bbci.co.uk/media/live/manifesto/audio/simulcast/dash/nonuk/dash_low/ak/bbc_radio_two.mpd" -vn -map 0:1 -c:a copy -movflags faststart "BBCr2live_dash_96k.m4a" NB: Press q when you wish to stop the recording; -map 0:1 is needed to record the best variant (96kbps HE-AAC), because the worst variant (48kbps HE-AAC) is chosen by default... ( π π ) ffmpeg version N-100546-g2c6f532-Reino Copyright (c) 2000-2021 the FFmpeg develo pers built with gcc 10.2.0 (GCC) configuration: --arch=x86 --target-os=mingw32 --prefix=/cygdrive/m/ffmpeg-wind ows-build-helpers-master/ffmpeg_local_builds/sandbox/cross_compilers/mingw-w64-i 686/i686-w64-mingw32 --cross-prefix=/cygdrive/m/ffmpeg-windows-build-helpers-mas ter/ffmpeg_local_builds/sandbox/cross_compilers/mingw-w64-i686/bin/i686-w64-ming w32- --extra-cflags='-march=pentium3 -mtune=athlon-xp -O2 -mfpmath=sse -msse' -- pkg-config=pkg-config --pkg-config-flags=--static --extra-version=Reino --enable -gpl --enable-gray --enable-version3 --disable-debug --disable-doc --disable-htm lpages --disable-manpages --disable-mediafoundation --disable-podpages --disable -txtpages --disable-w32threads --enable-avisynth --enable-frei0r --enable-filter =frei0r --enable-gmp --enable-libaom --enable-libass --enable-libfdk-aac --enabl e-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --ena ble-libgme --enable-libmp3lame --enable-libopenmpt --enable-libopus --enable-lib soxr --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-lib xvid --enable-libzimg --enable-mbedtls libavutil 56. 63.100 / 56. 63.100 libavcodec 58.115.102 / 58.115.102 libavformat 58. 65.100 / 58. 65.100 libavdevice 58. 11.103 / 58. 11.103 libavfilter 7. 95.100 / 7. 95.100 libswscale 5. 8.100 / 5. 8.100 libswresample 3. 8.100 / 3. 8.100 libpostproc 55. 8.100 / 55. 8.100 Input #0, dash, from 'http://a.files.bbci.co.uk/media/live/manifesto/audio/simul cast/dash/nonuk/dash_low/ak/bbc_radio_two.mpd': Duration: N/A, start: 1612143308.800000, bitrate: N/A Program 0 Stream #0:0(en): Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp (default) Metadata: variant_bitrate : 48000 id : audio=48000 Stream #0:1(en): Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp (default) Metadata: variant_bitrate : 96000 id : audio=96000 Output #0, ipod, to 'BBCr2live_dash_96k.m4a': Metadata: encoder : Lavf58.65.100 Stream #0:0(en): Audio: aac (HE-AAC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp (default) Metadata: variant_bitrate : 96000 id : audio=96000 Stream mapping: Stream #0:1 -> #0:0 (copy) Press [q] to stop, [?] for help [dash @ 0037be00] No longer receiving stream_index 0/A [ipod @ 06899fc0] Starting second pass: moving the moov atom to the beginning of the file size= 1079kB time=00:01:31.26 bitrate= 96.9kbits/s speed= 1x video:0kB audio:1070kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.855490% (I recorded just a 90s sample... ) Happy recordings... π β You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/ytdl-org/youtube-dl/issues/28032#issuecomment-770511113 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AIE2IZ3ETXXWUGA2OU6TQSTS4YCIVANCNFSM4W3TSRWA .
Checklist
Verbose log