Audio/video stream recording forums

Attention Visitor:
You may have to register or log in before you can post:
  • Click the register link to sign up.
  • Registered members please fill in the form below and click the "Log in" button.
To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Audio/video stream recording forums > Streaming media recording forum > Video stream recording
Register FAQ Members List Calendar Mark Forums Read

Reply Post New Thread
 
Thread Tools Display Modes
  #1  
Old 01-02-2018, 03:30 AM
Ed999 Ed999 is offline
Senior Member
 
Join Date: Feb 2009
Posts: 115
Ed999 is on a distinguished road
Default

How to record BBC iPlayer without signing-in


Download TV (or Radio) using only the 8-digit PID :


It's now possible to use YouTube-dl.exe to download from BBC iPlayer *without* using the Greasemonkey script that I've discussed previously on this forum.


Here is a method for downloading from BBC iPlayer using only the url address of the BBC iPlayer page. This method works for BBC TV shows and for BBC Radio shows.

This means that -

  • You can download without having to log-in to a BBC account
  • You can download without having to install Adobe's flash player
  • You can download without having to find the broadcast's hidden vpid number


One preliminary step, first. Download the YouTube-dl program (originally developed for downloading from YouTube, but its latest version can download from many websites which use DASH streams including the BBC's iPlayer site) -

https://rg3.github.io/youtube-dl/

The program does NOT require installing. Just put it in any convenient folder/directory.



And a second preliminary step. Download the ffmpeg program -

http://ffmpeg.zeranoe.com/builds/

Put it in the same folder/directory with the YouTube-dl program. That is now your working directory.



For a Radio show (a brief look at the simplest case first), you would use the following command line (actually two lines in this case!) -

Code:
    SET url=https://www.bbc.co.uk/programmes/00000000

    YouTube-dl.exe  -f "bestaudio[protocol*=dash]"  --add-metadata  "%url%"

1. Copy-and-paste the command (above) into a batch file (in Windows, a batch file is a plain text file with the extension .bat or .cmd instead of .txt), and put the batch file in the same folder as YouTube-dl.exe and ffmpeg.exe

2. Substitute the actual URL address of the iplayer page which plays the radio show for the one shown in my example. In effect you are just replacing the final 8 zero's in my example with the actual 8-digit PID (Programme ID).

3. Then run the batch file by double-clicking it.

The file which downloads should already have the extension .mp4 or .m4a (but if by chance it has not, you simply add either of those extensions). M4A is the iTunes extension.



For a TV show, use the following command line (actually two lines!) -

Code:
    SET url=https://www.bbc.co.uk/iplayer/episode/00000000

    YouTube-dl.exe  "%url%"  -f best  --add-metadata

1. Copy-and-paste the command (above) into a batch file (in Windows, a batch file is a plain text file with the extension .bat or .cmd instead of .txt), and put the batch file in the same folder as YouTube-dl.exe and ffmpeg.exe

2. Substitute the actual URL address of the iplayer page which plays the TV show for the one shown in my example. In effect you are just replacing the final 8 zero's in my example with the actual 8-digit PID (Programme ID).

3. Then run the batch file by double-clicking it.

The file which downloads should already have the extension .mp4 (but if by chance it has not, you simply add that extension).

Note that the command does not mention ffmpeg. This is NOT a mistake. The YouTube-dl program calls ffmpeg when it requires to use certain functions of ffmpeg, and calls it automatically so that you don't need to. Just bear in mind that things will go wrong if ffmpeg is not in the same folder as YouTube-dl.

Note that a tv show uses a different url address to that for a radio show, so be sure to use 2 separate batch files, as there is no benefit in trying to use only one. The 2nd line is also different in the case of a tv show.



That's all there is to it. But there are some additional options for a tv show, if you want to be in better control of the file you end up with.

Unlike radio (which usually has only 2 streams, a 128 kbps one and a 320 kbps one), TV has a large number of available streams. You can use the above command to get the default stream.

But if the default stream gets you a file that won't play (many of the available streams use the new avc3 codec, which only Windows 10 can play, so if you use Windows 7 you will instead prefer to have a file containing a stream which has the avc1 codec), then you need to get a list of the available streams ("formats").

Put the following command in a batch file (name it, say, TV_streams.bat) and run it (substitute the TV show's actual url for the one in my example, just as you did above) -

Code:
    SET url=https://www.bbc.co.uk/iplayer/episode/00000000

    YouTube-dl.exe "%url%" --list-formats > Formats.txt
Wait, then open the text file Formats.txt using Notepad (it will take perhaps a minute to download all the data into it). Then pick a stream: they will be listed by video size, e.g. 640x360, and by codec, e.g. avc1.

The following is a substitute batch file to download the TV stream you choose. This is a simple example (there are many other possibilities); but this is designed to avoid complicating matters -


Code:
    SET url=https://www.bbc.co.uk/iplayer/episode/00000000

    SET format=stream-uk-iptv_streaming_concrete_combined_sd_mf_akamai_uk_hls_https-1836

    YouTube-dl.exe  "%url%"  -f %format%  --add-metadata

Ideally, you will choose a stream which (as in this example) is a "combined" stream - as stated in the name of the stream. A combined stream is one which contains both audio and video.

I recommend the 1836 stream (shown in this example) because it contains AVC video (a.k.a. avc1 video), UK-style 25 fps (frames per second), an image size of 960x540 pixels, and good quality audio at 128 kbps.

Do NOT choose any video stream containing the avc3 codec, unless you have satisfied yourself that your computer can play that! If you are running Windows XP, Windows Vista, or Windows 7 it's a good bet you can't play a file containing the avc3 codec stream.


1. Copy-and-paste the command into a batch file (in Windows, a batch file is a plain text file with the extension .bat or .cmd instead of .txt), name the file (for example) TV_1836stream.BAT, and put the batch file in the same folder as YouTube-dl.exe and ffmpeg.exe

2. Substitute the actual URL address of the iplayer page which plays the TV show for the one shown in my example. In effect you're just replacing the final 8 zero's in my example with the actual 8-digit PID (Programme ID).

3. Substitute the actual name of your chosen stream, if you are not opting for my choice of the 1836 stream. (If you choose separate audio and video files, instead of a combined file, you'll need to make the necessary changes to line 3 of the batch file - so you'll need to do a Google search on the term ffmpeg to find an appropriate command.)

4. Then run the batch file by double-clicking it.


.
Reply With Quote
  #2  
Old 01-02-2018, 07:59 AM
Yelloworanges Yelloworanges is offline
Junior Member
 
Join Date: May 2017
Posts: 93
Yelloworanges is on a distinguished road
Default

Re: How to record BBC iPlayer without signing-in


Quote:
Originally Posted by Ed999 View Post
I recommend the 1836 stream (shown in this example) because it contains AVC video (a.k.a. avc1 video), UK-style 25 fps (frames per second), an image size of 960x540 pixels, and good quality audio at 128 kbps.
I usually choose this quality for video;
media bitrate="2800" encoding="h264" height="720" type="video/mp4" width="1280"

found usually in the "3200kbps/modav" path.

Some older video content may not have the 2800 (3200kbps) quality, but all recent content seems to have it.
Reply With Quote
Reply Post New Thread
Tags: , , ,



Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -6. The time now is 04:33 AM.


Powered by All-streaming-media.com; 2006-2011
vB forum hacked with Zoints add-ons