Pint-sized TMS
Vangelis forthnet
northmedia1 at the.forthnet.gr
Mon May 30 12:54:19 PDT 2016
On Mon May 30 10:35:47 BST 2016, Don Grunbaum wrote:
> Hi people
Hello to you too, Don :-)
> Is there a way of downloading the "Pint-sized TMS" videos
> such as http://www.bbc.co.uk/sport/cricket/36410032
... Well, I know I'm quoting here only the start of your question,
but when a stream is not encrypted (this one is not), then there usually
is a way (not always an easy one...).
> using either CLI or PVR GiP?
...As far as I can tell, SADLY NO!
Your query relates a lot to my recent post list here:
http://lists.infradead.org/pipermail/get_iplayer/2016-May/009090.html
After the beeb changes, GiP 2.94 is most
certainly unable to fetch BBC Sports Clips;
but while GiP 2.95dev has been (very recently) patched
to accommodate BBC News Clips changes, sadly
BBC Sports was left out from the equasion :-(
Indeed, with the latest public dev snapshot
(git-fc4929a) I get:
perl
get_iplayer-295dev.pl --type=tv --url="http://www.bbc.com/sport/cricket/36410032"
--modes=best --force
> INFO: Trying pid: http://www.bbc.com/sport/cricket/36410032 using type: tv
> INFO: Trying to stream pid using type tv
> INFO: pid not found in tv cache
> Matches:
>
> INFO: 1 Matching Programmes
> WARNING: No media streams found for requested programme versions and
> recording modes.
BBC Sports appears to use a different "audio_video" API
to the BBC News one, so the method described in detail
in my referenced list post of identifying a programme PID
(--pid) and feeding that to GiP 2.94 sadly does not apply
here - unless I have missed something, I haven't figured out
a method of using GiP for your query...
Thankfully (see below):
DISCLAIMER: The rest of this post can be justifiably
considered to be OT for this list; if your personal time is
indeed very precious or if you're just not interested in
learning more "techie" stuff, please ignore and move along...
1.
> the clip is being streamed in a desktop browser with Flash
> via AdobeHDS method by default
923kbps | HDS (mf_akamai_uk_hds) | p03wns2m | 704x396
> should you have PHP installed,
> AdobeHDS.php script installed, Mozilla Firefox installed
> together with HDS Link Detector addon, you can easily
> fetch that clip as an .FLV file (your favourite search engine
> is your friend).
The above is still valid for this clip - NB, for WinXP the last
PHP version that works is the EOL'ed 5.4.45
(Useful links for Windows OSes:
http://php.net/manual/en/install.windows.manual.php
http://php.net/manual/en/install.windows.commandline.php
https://github.com/K-S-V/Scripts
https://addons.mozilla.org/el/firefox/addon/hds-link-detector/ )
2. By right clicking on the Flash player, either before playback
=> p03wns2m / programme / 0
or after playback has commenced
=> 923kbps | HDS (mf_akamai_uk_hds) | p03wns2m | 704x396
you can get the all-important "vpid" string, that provides access to
streams; so, vpid=p03wns2m
You can then find stream details manually via "mediaselector" URLs,
since GiP can't be fed a vpid value :-(
BBC Sports by default uses the "journalism-pc" mediaset, so in
your browser load:
http://open.live.bbc.co.uk/mediaselector/5/select/version/2.0/mediaset/journalism-pc/vpid/p03wns2m
(uses geo-filter), and therein you shall find details
for RTMP streams, in the {service="iplayer_streaming_h264_flv_high"}
section; it is fairly easy to compose an rtmpdump command yourself...
The template for the akamai CDN is:
rtmpdump -r "rtmp://server:443/ondemand" -a "ondemand?authString -f "WIN
21,0,0,242" -W
"http://emp.bbci.co.uk/emp/SMPf/1.16.6/StandardMediaPlayerChromelessFlash.swf"
-p "http://www.bbc.co.uk" -C O:1 -C O:0 -y identifier
"filename-of-your-choice.flv"
Values of <server>, <authString> & <identifier> to be copied
without the quotation marks - be careful not to insert unneeded
whitespace/line breaks...
3. If you are more proficient in FFmpeg commands, then
use the "journalism-http-tablet" mediaset:
http://open.live.bbc.co.uk/mediaselector/5/select/version/2.0/mediaset/journalism-http-tablet/vpid/p03wns2m/
This provides AppleHLS streams; easier to use
is the "legacy" one under {service="mobile_streaming_1500"},
the rest are the newer "Video Factory" streams which can also be
dumped but in a more complex procedure....
The template FFmpeg command for the unique akamai CDN is:
ffmpeg -i href -c copy "filename-of-your-choice.ts"
Value of <href> can include the quotation marks
(though usually unneeded, because no whitespace present).
(Optional) Remux to MP4 container:
ffmpeg -i "filename-of-your-choice.ts" -c copy -bsf:a aac_adtstoasc
"filename-of-your-choice.mp4"
4. As another approach to downloading Sports Clips
you can use the open-source, Python based, CLI tool
"youtube-dl.exe"
http://youtube-dl.org/latest/
The .exe includes Python, no separate install is needed...
By first running
youtube-dl.exe -F "http://www.bbc.co.uk/sport/cricket/36410032"
you can preview the available formats; youtube-dl.exe uses
the Video Factory AppleHLS streams
retrieved from the "iptv-all" mediaset
http://open.live.bbc.co.uk/mediaselector/5/select/version/2.0/mediaset/iptv-all/vpid/p03wns2m/
For best results, FFmpeg.exe is needed alongside youtube-dl.exe
(or put in PATH, so that youtube-dl.exe can find it...).
youtube-dl "http://www.bbc.co.uk/sport/cricket/36410032"
will download a 704x396p 1680kbps (V=1550+A=128)
50FPS .mp4 file.
I have provided here sufficient info for anyone
wanting to fetch BBC Sports Clips; please refrain from
asking further support here in the list, as AdobeHDS.php,
RTMPdump, FFmpeg, youtube-dl etc. have their own
support infrastructure online; (almost) everything is there
to search for, find, learn - I have merely given you the yeast
to make your own bread...
Best regards,
Vangelis.
More information about the get_iplayer
mailing list