Recent

Author Topic: Youtube Downloader in Pascal  (Read 14971 times)

tjpren

  • Jr. Member
  • **
  • Posts: 67
Youtube Downloader in Pascal
« on: January 27, 2012, 11:59:29 am »
Hello Forum,

I was wondering if anyone had success writing a youtube download app.

I've written a little app using synapse, that can download a variety of files - even flv's - from a web server, but when I try to download a link from Youtube, my file is empty.

I've looked over some source code that was in a Delphi package and a python app, and think that the issue is in the header info?

Any thoughts.

Code: [Select]
procedure TForm1.Button1Click(Sender: TObject);
var
  fs : TFileStream;

begin
   fs := TFileStream.Create('C:\Download\Youtube', fmOpenWrite or fmCreate);
   try
      HttpGetBinary('http://192.168.1.4/Test/Songs/abc.flv', fs);
   finally
      fs.Free;
   end;

end;

typo

  • Hero Member
  • *****
  • Posts: 3051

tjpren

  • Jr. Member
  • **
  • Posts: 67
Re: Youtube Downloader in Pascal
« Reply #2 on: January 28, 2012, 01:19:05 am »
Thanks Typo,

It would appear as though somewhere within the YouTube URL, is an actual location, from which you can initiate a download.  I've read that YouTube regularly change the method of hiding this link.  A lot of CAC's code is spent on getting this link using RegExpr.pas.  I noticed a similar approach in a Delphi.

From a learing perspective, I'm going to look more deeply into how this is accomplished.

When I tried CAC, it failed to download, so in the 8months since the last release, youtube have changed their method again.

However, apart from hiding the link, the actual method of download is accomplished with Synapse.

Thanks for the help.

Regards

mica

  • Full Member
  • ***
  • Posts: 196
Re: Youtube Downloader in Pascal
« Reply #3 on: January 28, 2012, 03:56:26 pm »
Look at the SVN
 
the Youtube issue seems to be fixed

http://cac.svn.sourceforge.net/viewvc/cac/source/

CFA2k

  • Newbie
  • Posts: 1
Re: Youtube Downloader in Pascal
« Reply #4 on: February 14, 2012, 10:29:08 pm »
@tjpren
I´m the Developer of CaC.
If you have any questions, feel free to send me a message :)

cdbc

  • Hero Member
  • *****
  • Posts: 2726
    • http://www.cdbc.dk
Re: Youtube Downloader in Pascal
« Reply #5 on: May 18, 2019, 09:47:18 am »
VLC...... :-)
If it ain't broke, don't fix it ;)
PCLinuxOS(rolling release) 64bit -> KDE6/QT6 -> FPC Release -> Lazarus Release &  FPC Main -> Lazarus Main

Thaddy

  • Hero Member
  • *****
  • Posts: 18960
  • Glad to be alive.
Re: Youtube Downloader in Pascal
« Reply #6 on: July 03, 2025, 07:04:27 pm »
Are you still in win95 era by commenting on a 13 + year old thread?
Recovered from removal of tumor in tongue following tongue reconstruction with a part from my leg.

yus

  • Jr. Member
  • **
  • Posts: 62
Re: Youtube Downloader in Pascal
« Reply #7 on: July 17, 2025, 01:40:58 am »
Hello.
I haven't tested it in a while, but it used to work. https://github.com/seryal/wevido

delphius

  • Jr. Member
  • **
  • Posts: 83
Re: Youtube Downloader in Pascal
« Reply #8 on: July 18, 2025, 07:18:37 pm »
I haven't tested it in a while, but it used to work. https://github.com/seryal/wevido

And what about decoding Youtube cipher signature?  ::)
fpmtls - ssl/tls 1.3 implementation in pure pascal
fpmailsend - sending a simple email message
pascal-webui - use web browser as gui and fpc as backend

 

TinyPortal © 2005-2018