|
Answer» Hi I'm making this batch script to download a video in MP4 from youtube using VLC with the command line. and it works fine for me. VLC_Youtube_Downloader.bat
Code: [Select]echo off REM Downloading a video from youtube using VLC with the command line by (c) Hackoo 2017 Title Si Lemhaf - Kharrej Legrinta Elli Fik by (c) Hackoo 2017 mode con:cols=65 lines=3 & COLOR 0E Taskkill /IM "vlc.exe" /F >nul 2>&1 echo. echo Please wait a while ... The download is in progress ... SET Title=Si Lemhaf - Kharrej Legrinta Elli Fik by (c) Hackoo 2017 set "VLC_URL=http://www.videolan.org/vlc/download-windows.html" set "URL=https://www.youtube.com/watch?v=KDI1C27zEC0" set "File=SiLmehaf.mp4" IF /I "%PROCESSOR_ARCHITECTURE%"=="x86" ( Set "vlc=%ProgramFiles%\VideoLAN\VLC\vlc.exe" ) ELSE ( Set "vlc=%ProgramFiles(x86)%\VideoLAN\VLC\vlc.exe" )
If Not Exist "%vlc%" ( Cls & COLOR 0C echo. Echo "The VLC program is not installed on your system" TimeOut /T 5 /NoBreak>nul Start "" %VLC_URL% Exit )
"%vlc%" -vvv "%URL%" --qt-start-minimized --qt-notification=0 --sout=#transcode{vcodec="h264",vb="512",fps="23.97",scale="1",acodec="mpga",ab="128","channels=2",samplerate="44100"}:standard{access="file",mux=mp4,dst=%File%} vlc://QUIT" REM Starting the video in fullscreen with VLC Start "" "%vlc%" -f --meta-title="%Title%" %File% But, my problem is why some URLs from Youtube dosen't work ? like this ONE :
https://www.youtube.com/watch?v=TGtWWb9emYI
I got this error from VLC program Can not recognize the format of the input media Lots of this in vlc log for that problem video
Code: [Select]http error: error: HTTP/1.1 403 Forbidden
Quote from: Salmon Trout on April 18, 2017, 01:23:23 PM Lots of this in vlc log for that problem video
Code: [Select]http error: error: HTTP/1.1 403 Forbidden
So, did you think that error is coming with a copyright PROTECTED url from youtube ?Could be. Yepper...
|