| Comments: |
![[User Picture]](http://l-userpic.livejournal.com/63643632/11038711) | From: dranon Fri, 21-Nov-2008 4:54 AM (UTC)
Keepvid | (Link)
|
Keepvid figures out the links for the flv and the mp4 (if there is one).
![[User Picture]](http://l-userpic.livejournal.com/5887295/515656) | From: jwz Fri, 21-Nov-2008 4:58 AM (UTC)
Re: Keepvid | (Link)
|
Gee. Is that what I asked?
![[User Picture]](http://l-userpic.livejournal.com/63643632/11038711) | From: dranon Fri, 21-Nov-2008 5:23 AM (UTC)
Re: Keepvid | (Link)
|
Sorry, no, you're right, it's not.
Use http://www.youtube.com/get_video?video_id=video_id&t=t&fmt=18 for the mp4.
video_id is whatever comes after the v= part in the youtube watch url.
t is whatever is inside quotes after the "t": part of the var swfArgs declaration.
I have no experience with the HD version.
![[User Picture]](http://l-userpic.livejournal.com/5887295/515656) | From: jwz Fri, 21-Nov-2008 6:00 AM (UTC)
Re: Keepvid | (Link)
|
Ok, it looks like t= and t= alone is the key. I had been using all of the various swfArgs parameters, and if you provide all of them in the obvious way, it gives you the low-res version. But if you just use video_id, t, and fmt=22, you get the HD MP4.
Thanks!
![[User Picture]](http://l-userpic.livejournal.com/70524252/169583) | From: twiin Fri, 21-Nov-2008 6:58 AM (UTC)
Re: Keepvid | (Link)
|
If you're using Safari, Window > Activity shows all resources being used by open web pages, including Flash video assets. I don't know how to generate the URL for the HD version, but the one I captured for this HD video looks radically different from the standard get_video URL... it's under the cache.googlevideo.com domain and includes a number of new-looking parameters.
Disappointingly, I haven't been able to find any of the crucial-looking parameters (in particular, id and signature) in the HTML source. It's possible they're being generated by the SWF somehow... :(
![[User Picture]](http://l-userpic.livejournal.com/5887295/515656) | From: jwz Fri, 21-Nov-2008 6:01 AM (UTC)
| (Link)
|
The "Activity" trick notably doesn't work for the MTV stuff, and I'm not entirely clear on how that's possible, since I thought all Flash network connections went through the browser.
It looks like the MTV videos are getting streamed with Flash Communication Server (macromedia-fcs, port 1935). You'll need to do something significantly more clever to capture these.
They're using rtmp, which is a proprietary protocol but could be something other than FCS (such as red5). You can figure out what server they're connecting to with something like netcat or wireshark. Assuming they're not doing anything weird/special over rtmp, a standard rtmp ripper should work.
I did some more digging. Watch for the player to grab a url that looks like this: http://www.mtv.com/player/includes/mediaGen.jhtml?uri=mgid:uma:video:mtv.com:253852&id=1518072&vid=253852&ref=http://www.mtv.comWhen you go to that url you'll get some xml that contains src tags for different resolutions, and you'll see a url like this: rtmp://cp10740.edgefcs.net/ondemand/mtvn shrdstor/_!/mtvi/bands/v/veronicas_the/u ntouched_full_320.flv Put that url into your favorite rtmp stream ripper and you're good to go. BTW, the fact that rtmp is such a hassle to rip is exactly why we used it at my company (Grooveshark) for music playback until a couple of weeks ago, when we said fuck it and switched over to http streaming.
the entire whose catalog? i searched for skinny puppy videos and they showed no results. i coulda sworn i saw a skinny puppy video on mtv once.
![[User Picture]](http://l-userpic.livejournal.com/5887295/515656) | From: jwz Fri, 21-Nov-2008 6:29 AM (UTC)
| (Link)
|
Yeah, there was a press release that claimed this was the entire MTV catalog. That claim is clearly bullshit, unless by "entire catalog" they mean "of stuff currently in rotation". They had about a 10% hit rate on my first couple dozen searches (of videos I'm certain I saw on MTV!)
bittorrent is still the best place to download music videos, apparently.
On the topic of ripping stuff, do you know if there is an easy way to reverse the process you use to cram all the mp3s for one of your mix tapes into one file, such that I could download your mix tape and break them apart?
![[User Picture]](http://l-userpic.livejournal.com/78674788/922107) | From: leolo Fri, 21-Nov-2008 9:42 AM (UTC)
| (Link)
|
You must be new here.
If such a "stream ripper" program existed, you would probably find it using your favorite search engine.
![[User Picture]](http://l-userpic.livejournal.com/63438989/520978) | From: jayp39 Fri, 21-Nov-2008 11:25 PM (UTC)
| (Link)
|
I thought this was the lazyweb.
It's also the "please don't get Jamie sued" web.
It was my impression the MTV upload was going to be done in multiple stages, maybe they don't want to clog the tubes.
You have to do it slowly, it's not a truck, you can't jsut throw 10,000 videos on it all at once.
Ten movies streaming across that, that Internet, and what happens to your own personal Internet? I just the other day got... an Internet was sent by my staff at 10 o'clock in the morning on Friday. I got it yesterday [Tuesday]. Why? Why? Because it got tangled up with all these things going on the Internet commercially.
Thanks for the script. Very useful. It even inspired me to continue study Perl.
So apparently there is now not only fmt=18 for slightly higher quality MP4, but also fmt=6 which serves a much higher video quality MP4 (30 fps 900 kbps, as opposed to 24 fps 512 kbps) though unfortunately also lower quality audio (96 kbps mono rather than 128 kbps stereo). Very few videos overall have a fmt=22 HD version, but so far I have been lucky with fmt=6 on every try.
![[User Picture]](http://l-userpic.livejournal.com/5887295/515656) | From: jwz Wed, 18-Feb-2009 7:15 PM (UTC)
fmt=6 | (Link)
|
What the hell? Why would they turn the audio to mono?
Is this crap actually documented anywhere yet?
It appears to be meant for the iPhone client. My conjecture based on that is they assumed that since it wouldn’t make a big difference in the settings where these things are watched, they could avoid doubling the size of the streams outright – just a dumb guess.
It’s aggravating that none of this appears to be documented anywhere on the YouTube site (or the wider Google mothership), much as I’ve searched.
![[User Picture]](http://l-userpic.livejournal.com/5887295/515656) | From: jwz Wed, 18-Feb-2009 7:23 PM (UTC)
| (Link)
|
I found this which claims: # default: MP3, 64 kbps, 22.05 KHz, mono # fmt=5: MP3, 64 kbps, 22.05 KHz, mono # fmt=6: MP3, 66 kbps, 44.1 KHz, mono # fmt=13, 3GP, AMR or AAC audio # fmt=17, 3GP, AMR or AAC audio # fmt=18: AAC, 126 kbps, 44.1 KHz, stereo # fmt=22: AAC, 248 kbps, 44.1 KHz, stereo (only if original was 1280x720) # fmt=34: AAC, 68 kbps, 22.05 KHz, stereo # fmt=35: AAC, 112 kbps, 44.1 KHz, stereo (rare)
Buried in some forum I found this table from someone who uploaded an HQ-video movie and checked the results. (Yes, really, it was an image. With the video/audio columns were interleaved. I managed to bother to shuffle the columns in Gimp, but have yet to get bothered enough to transcribe it.)
Looks like the choice is fmt=22 when available, otherwise fmt=18 for stuff where you care about the audio quality more than the video, fmt=6 for the reverse case.
I wonder how hard it would be to automate downloading the clip in both fmt=18 and fmt=6, demuxing the copies, and muxing the high-quality video and sound streams back together… | |