extract audio with youtube-dl on windows

那年仲夏 提交于 2019-12-01 06:10:34

ffmpeg is not a Python module. Take a look at the code of youtube-dl in the FFmpegExtractAudioPP class.

It uses this call to figure out if the executable exists or not. It checks in your current path:

subprocess.Popen([exe, '-version'], stdout=subprocess.PIPE, stderr=subprocess.PIPE).communicate()

You'll need to download the Windows builds of ffmpeg and put them in your current path, probably making sure that they do not have .exe at the end of their names.

A quick fix for windows users:

1.Download the ffmpeg package from http://ffmpeg.zeranoe.com/builds/, unzip it, copy ALL the contents of the Bin directory to the directory where youtube-dl.exe is located.

2.Using DOS navigate to the directory where youtube-dl is located and run using the command: youtube-dl --extract-audio --audio-format mp3

Robert Rowntree

U can use the rtsp stream url for the format type 1 feed listed in the common Youtube api.. call it for feed info...

get youtube feed which contains a number of urls...

get the 'format type 1' url

call that with an RTSP client and you can store the audio directly...

https://android.stackexchange.com/questions/18469/is-android-single-task-or-multitasking-and-multithreading

see 'youtube feed' in the above for how to get type 1 url

http://snipplr.com/view/63341/youtube-rtsp-cli-request--audio-track-only-p2/

see above for how to get audio once you have the url

more background at : http://snipplr.com/view/56509/youtube-rtsp-cli-request--audio-track-only/

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!