Saving Real Media streams

Saving Real Media streams

I like to watch Berkley’s stream lectures. I do not like to have to start at the beginning of a lecture and wait for the buffer to catch up to where I was last time before I got interrupted. After some googling I was able to find out how to save real media streams with mplayer. Below is a bash script I wrote in order to download EE 140 lectures:

for fname in "20040120" "20040122" "20040127" "20040129" "20040203" "20040205""20040210" "20040212" "20040217" "20040219" "20040224" "20040226" "20040302""20040304" "20040309" "20040311" "20040316" "20040318" "20040323" "20040325" "20040330" "20040401" "20040406" "20040408" "20040413" "20040415" "20040420" "20040422" "20040427" "20040429" "20040504" "20040506" "20040511"
	mplayer -bandwidth 2000000 -cache 3000 -noframedrop -dumpfile "$fname.rm" -dumpstream $url/"$fname.rm"

-bandwidth 2000000 set the download rate to 2Mbps without this data downloads in real time which means it takes 60 minues to download a 60 minute lecture.

-cache 3000 is useful because you are downloading a lot faster than real time

-noframedrop and -dumpfile should be pretty self explanatory

-rtsp is the proprietary protocol which real media streams with $url is taken from inspecting the .rm files

As far as I know this method can be employed for any streaming media mplayer can playback. I haven’t tried it on anything except the Berkley lectures.

Refereces: (howto stream audio only)