{"id":236,"date":"2008-05-13T12:43:31","date_gmt":"2008-05-13T17:43:31","guid":{"rendered":"http:\/\/www.pchristensen.com\/blog\/?p=236"},"modified":"2013-12-23T12:08:14","modified_gmt":"2013-12-23T19:08:14","slug":"ripping-and-encoding-streaming-rm-or-how-i-defeated-realplayer","status":"publish","type":"post","link":"http:\/\/pchristensen.com\/blog\/articles\/ripping-and-encoding-streaming-rm-or-how-i-defeated-realplayer\/","title":{"rendered":"Ripping And Encoding Streaming RM, or How I Defeated RealPlayer"},"content":{"rendered":"<p>I&#8217;ve known (and <a href=\"http:\/\/www.pchristensen.com\/blog\/articles\/mits-opencourseware-caveats\/\" target=\"_self\">written about<\/a>) MIT&#8217;s OpenCourseWare project for a while but never gone through any of the courses.  I&#8217;ve found the first one I want to work through on Data Wrangling&#8217;s outstanding <a href=\"http:\/\/www.datawrangling.com\/hidden-video-courses-in-math-science-and-engineering.html\" target=\"_blank\">Hidden Video Courses in Math, Science, and Engineering<\/a> page.  One of the courses in the Mathematics header is <a href=\"http:\/\/ocw.mit.edu\/OcwWeb\/hs\/geb\/VideoLectures\/index.htm\" target=\"_blank\">Godel, Escher, Bach: A Mental Space Odyssey<\/a>, and I decided to bite.<\/p>\n<p><a href=\"http:\/\/www.amazon.com\/exec\/obidos\/ASIN\/0465026567\/pchristense03-20\"><img loading=\"lazy\" decoding=\"async\" style=\"float:right;margin-left:4px;border:0px;\" src=\"http:\/\/ecx.images-amazon.com\/images\/I\/41V5ZTF24CL._SL160_.jpg\" alt=\"Godel, Escher, Bach: An Eternal Golden Braid\" width=\"111\" height=\"160\" \/><\/a><\/p>\n<p>The book <a href=\"http:\/\/www.amazon.com\/o\/asin\/0465026567\/pchristense03-20\" target=\"_blank\">Godel, Escher, Bach: An Eternal Golden Braid<\/a>, is widely praised as being an important, mind-bending, eye-opening book, but the reviews I&#8217;ve seen generally fall have fallen into two categories:<\/p>\n<ul>\n<li>people who have tried to read it but quit about 1\/3 of the way through, but still proudly display it on their shelves as a badge of honor<\/li>\n<li>b) people who have read it and understand it, but don&#8217;t feel like trying to explain it to the uninitiated.<\/li>\n<\/ul>\n<p>Since the MIT OCW course was a summer lecture series for high school students, I figured I could keep up.  And by watching the lectures first, I&#8217;m hoping the book will be easier when I get around to reading it.  It doesn&#8217;t seem like a book where I should worry about spoiling the ending.<\/p>\n<p>There was one problem that took me a while to overcome:  the lectures were in streaming .rm (Real Media) format.  That means RealPlayer.  I am not friends with RealPlayer &#8211; I cut my ties with Real in 2002 and vowed never to have their software on any of my computers again.  If you don&#8217;t understand my revulsion, just Google &#8220;<a href=\"http:\/\/www.google.com\/search?q=real+player+sucks\" target=\"_blank\">real player sucks<\/a>&#8221; (477,000 hits).<\/p>\n<p>So after a few days of tinkering, I came up with this solution for ripping rm streams and encoding them in a different format (I chose .mp4 so I can watch them on computer or <a href=\"http:\/\/www.amazon.com\/o\/asin\/B000JO1MU4\/pchristense03-20\" target=\"_blank\">video iPod<\/a>).  It takes about 20-25 mintues per hour of media but can be setup up in batches to run overnight.  In my opinion, that&#8217;s a small price to avoid dealing with RealPlayer.<\/p>\n<p>[NOTE: This is for Windows XP.  YMMV on other platforms]<\/p>\n<p><!--more--><\/p>\n<p><strong>First<\/strong>, install these 3 programs:<\/p>\n<ul>\n<li><a href=\"http:\/\/www.mplayerhq.hu\/design7\/dload.html\" target=\"_blank\">MPlayer<\/a> &#8211; DON&#8217;T download the GUI version &#8211; you need the command line options to rip the stream.<\/li>\n<li><a href=\"http:\/\/www.free-codecs.com\/Real_Alternative_Lite_download.htm\" target=\"_blank\">Real Alternative Lite<\/a> &#8211; RealPlayer codecs without the player<\/li>\n<li><a href=\"http:\/\/www.ipod-video-converter.org\/\" target=\"_blank\">Free iPod Video Converter<\/a> &#8211; there are zillions of programs that convert media files if you have the right codecs (it took me a while to figure that out) &#8211; this was the simplest, most straightforward one I came across<\/li>\n<\/ul>\n<p><strong>Second<\/strong>, rip the stream from the web. Open a Command window, go to the MPlayer directory, and type:<\/p>\n<ul>\n<li><span><span style=\"color: #000000;\">mplayer -playlist [file URL] -dumpstream -dumpfile [destination file name]<\/span><\/span><\/li>\n<\/ul>\n<p>This takes a while &#8211; streams download at 1-5x real time, so the 60 minute GEB lectures each took about 15-20 minutes each for me.  Also, it doesn&#8217;t appear to be doing anything when it runs &#8211; it says something like &#8220;Cache set to 320KB&#8221;.  It&#8217;s working, just walk away.  You might be able to get multiple streams with one command by tweaking the command line args &#8211; let me know if you find something like it in the <a href=\"http:\/\/www.mplayerhq.hu\/DOCS\/HTML\/en\/index.html\" target=\"_blank\">MPlayer documentation<\/a>.<\/p>\n<p>[EDIT: Apparently for MIT OCW streams, you can <a href=\"http:\/\/mit-ocw-thai.eng.chula.ac.th\/OcwWeb\/Global\/OCWHelp\/help.htm#26\" target=\"_blank\">download them directly<\/a> by changing the URL.  Just change &#8220;<span class=\"bodycopy\"> http:\/\/mfile.akamai.com\/7870\/rm\/mitstorage.download.akamai.com\/7870&#8243; at the beginning of the streaming URL with &#8220;<\/span><span class=\"bodycopy\">http:\/\/ocw.mit.edu\/ans7870&#8243;.  This way you can download them at full speed instead of streaming speed.  Thanks Sharma!]<br \/>\n<\/span><\/p>\n<p><strong>Third<\/strong>, once you have the ripped files, open Free iPod Video Converter, add the .rm files you ripped, and hit &#8220;Convert&#8221;.  The defaults are fine &#8211; it sets video and audio quality based on the values in the source.  This took about 5 minutes per hour on the MIT OCW files I used.<\/p>\n<p>That&#8217;s it!  Now instead of being tied to a computer with internet connection, you can take your learning on the go!  Now go back to the <a href=\"http:\/\/www.datawrangling.com\/hidden-video-courses-in-math-science-and-engineering.html\" target=\"_blank\">Hidden Video Courses in Math, Science, and Engineering<\/a> page and prepare for some seriously nerdly workouts!<\/p>\n<p>&#8212;&#8212;&#8212;&#8212;&#8211;<\/p>\n<p>UPDATE: My original streamdumps on a DSL line (~200K\/sec) did not work right &#8211; the had correct file sizes but blacked out 50-70% of the way through. The mp4 conversions from those files just clipped off when the files blacked out. I tried downloading them using the direct downloads but the files got clipped and were only 30-40% of the expected file size. I tried the direct downloads when I had access to a T1 line and they all downloaded completely and played to the end. I&#8217;m not sure what the difference was, but check your .rm files to make sure they are the right size and play all the way to the end.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;ve known (and written about) MIT&#8217;s OpenCourseWare project for a while but never gone through any of the courses. I&#8217;ve found the first one I want to work through on Data Wrangling&#8217;s outstanding Hidden Video Courses in Math, Science, and Engineering page. One of the courses in the Mathematics header is Godel, Escher, Bach: A [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_genesis_hide_title":false,"_genesis_hide_breadcrumbs":false,"_genesis_hide_singular_image":false,"_genesis_hide_footer_widgets":false,"_genesis_custom_body_class":"","_genesis_custom_post_class":"","_genesis_layout":"","_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[8],"tags":[],"class_list":["post-236","post","type-post","status-publish","format-standard","category-education","entry"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/pazgP-3O","_links":{"self":[{"href":"http:\/\/pchristensen.com\/blog\/wp-json\/wp\/v2\/posts\/236","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/pchristensen.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/pchristensen.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/pchristensen.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/pchristensen.com\/blog\/wp-json\/wp\/v2\/comments?post=236"}],"version-history":[{"count":0,"href":"http:\/\/pchristensen.com\/blog\/wp-json\/wp\/v2\/posts\/236\/revisions"}],"wp:attachment":[{"href":"http:\/\/pchristensen.com\/blog\/wp-json\/wp\/v2\/media?parent=236"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/pchristensen.com\/blog\/wp-json\/wp\/v2\/categories?post=236"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/pchristensen.com\/blog\/wp-json\/wp\/v2\/tags?post=236"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}