flat assembler
Message board for the users of flat assembler.

Index > Windows > YouTube Downloading

Author
Thread Post new topic Reply to topic
me239



Joined: 06 Jan 2011
Posts: 200
me239
Hey guys! I didn't really know where to post this, but anyways, here it goes. How do I manually download videos from YouTube using the URL. I want to write a simple YouTube downloader in Windows, but each method I see is outdated as YouTube changes it's code quite frequently. Does anyone know a fail proof method of downloading the videos without using another product or program? Thanks Smile
Post 25 May 2011, 05:48
View user's profile Send private message Reply with quote
ManOfSteel



Joined: 02 Feb 2005
Posts: 1154
ManOfSteel
If you know Python...
http://rg3.github.com/youtube-dl/
It's regularly updated to reflect the changes on YouTube.com
Post 25 May 2011, 09:02
View user's profile Send private message Reply with quote
asmhack



Joined: 01 Feb 2008
Posts: 431
asmhack
Why downloading the video ? It's stored in your browser's temporary directory after a simple watch.
Post 25 May 2011, 15:43
View user's profile Send private message Reply with quote
ManOfSteel



Joined: 02 Feb 2005
Posts: 1154
ManOfSteel
You may be unable to watch the video to begin with if, for example, you don't have Flash installed.
Also there are plugins/extensions in some browsers (Opera, Firefox) that allow you to do the same, but for the past 3 years you may have noticed this is a programming-related forum. :p
Post 25 May 2011, 15:55
View user's profile Send private message Reply with quote
bitshifter



Joined: 04 Dec 2007
Posts: 764
Location: Massachusetts, USA
bitshifter
edit: post removed


Last edited by bitshifter on 26 May 2011, 01:39; edited 1 time in total
Post 25 May 2011, 18:16
View user's profile Send private message Reply with quote
ManOfSteel



Joined: 02 Feb 2005
Posts: 1154
ManOfSteel
bitshifter wrote:
If a mod could move this to the heap please...

From the OP:
me239 wrote:
I want to write a simple YouTube downloader in Windows

And I presume me239 wants to write it in assembly, so it's in the right subforum. The youtube-dl Python script I posted a link to is only meant as a reference. Alternatively it should be in Projects and Ideas.
Post 25 May 2011, 19:29
View user's profile Send private message Reply with quote
LocoDelAssembly
Your code has a bug


Joined: 06 May 2005
Posts: 4633
Location: Argentina
LocoDelAssembly
ManOfSteel perfectly reflects why I'm delaying the moving, if the thread remains with this trend (providing existing tools to get the job done and not implement anything), I'll move it to Heap, if it will move towards making a tool in Python or any HLL then I'll move to HLL, and if it will move towards making a tool in assembly then no move will be done. I didn't consider moving to Project and Ideas, I think it would be better to start a new thread so the first post can start at the initial implementation steps.
Post 25 May 2011, 21:25
View user's profile Send private message Reply with quote
JohnFound



Joined: 16 Jun 2003
Posts: 3502
Location: Bulgaria
JohnFound
The project is interesting and it should not be so hard to be implemented - just one low-to-medium level exercise on network programming.
However, the big problem here is the fact, that YouTube all the time make changes to the format of their pages in order to make difficulties just for creators of such kind of projects. In my impression, the usual life without update of such programs is round about several months.
The proper approach is to think about implementing some more sophisticated algorithm that to search and extract the proper URL even if the format changes - and this is not so trivial task anymore.
Post 25 May 2011, 21:26
View user's profile Send private message Visit poster's website ICQ Number Reply with quote
asmhack



Joined: 01 Feb 2008
Posts: 431
asmhack
asmhack wrote:
Why downloading the video ? It's stored in your browser's temporary directory after a simple watch.

ManOfSteel wrote:
You may be unable to watch the video to begin with if, for example, you don't have Flash installed.
Also there are plugins/extensions in some browsers (Opera, Firefox) that allow you to do the same, but for the past 3 years you may have noticed this is a programming-related forum. :p

-------------------------------------------------------------------
first sign of broad rule:
me239 wrote:
Hey guys! I didn't really know where to post this, but anyways, here it goes.

as I can I understand from the below question the minimalistic goal is to get a .flv (or whatever extension) file from the web.:
me239 wrote:

How do I manually download videos from YouTube using the URL.

first sign of desperation:
me239 wrote:

I want to write a simple YouTube downloader in Windows, but each method I see is outdated as YouTube changes it's code quite frequently.

second sign of desperation:
me239 wrote:

Does anyone know a fail proof method of downloading the videos without using another product or program? Thanks Smile


So,
here we go man of steel, looking at the last sign of desperation, we could discern that me wants just to get that video with a fail proof method without using another product, program, code, python framework or winsock client downloader written in asm with flash video decoder includes.

My method is the best
and if you want to see some code in it
I would be glad to see some code of yours, in asm, doing that process and finding that precious flv file inside of an ugly temp folder. Just don't mess up the gui (:
Post 25 May 2011, 21:41
View user's profile Send private message Reply with quote
typedef



Joined: 25 Jul 2010
Posts: 2913
Location: 0x77760000
typedef
If you go on any youtube video page and Right click and select view source.

You'll find that the flash video is embedded with, of course, the embed tag.

It seems like they add more attributes and properties to the embed tag element .
For example, you'll find something like rv.x.xxx = value;
Those are not default DOM element attributes.

So the thing would be to make an HTTP POST request ( Search for video ), then use some XML parsing technique to parse the results into a list view or list box and then, navigate to that video page and get its contents and search for the embed tag. That would mean coming up with your own algorithm to search for attributes & values for the video. And also, the file itself (the video file) can not be played alone without some YouTube server sided scripts(I assume).

There has to be another easier way though Very Happy
Post 25 May 2011, 21:41
View user's profile Send private message Reply with quote
me239



Joined: 06 Jan 2011
Posts: 200
me239
OK, I had no idea this thread would get this out control with people questioning the philosophy of my post. My request is simple; how do I download YoutTube videos from the URL using SOLELY FASM for Windows? I looked for rv.x.xxx = value and found the embedded player, but not the video.
Post 26 May 2011, 04:54
View user's profile Send private message Reply with quote
typedef



Joined: 25 Jul 2010
Posts: 2913
Location: 0x77760000
typedef
another simple way would be to make your own website that in php handles requests from your fasm proggy.
the php website will do all the work and then give you the decoded video link then you can download it using DownloadUrlToFile api.

i'll try it myself right now.
Post 26 May 2011, 17:53
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.

Website powered by rwasa.