POPEYE wrote: ↑Sat Dec 30, 2017 11:50 pm
Where from does it take path to youtube-dl?
There's more than one answer.
For use by omxplayerGUI:
Basically a working binary or link to an installed full Python version of youtube-dl is required in either /usr/bin or /usr/local bin.
A standard version downloaded from the youtube-dl website and installed into either directory will work, but is quite slow (see timings below).
To use the youtube-dl-server and to get better performance a full youtube-dl Python version has to be installed.
On Jessie by default git is used to install youtube-dl in your home folder and a symbolic link to it is created in /usr/bin.
On Stretch pip is used to install youtube-dl. This installation creates a symbolic link in /usr/local/bin.
Both versions are supported on Jessie and Stretch. The youtube-dl version in your home directory has the disadvantage that it won't revive a user change, but unfortunately pip on Jessie has been broken for a long time. But you can safely install the Stretch versions manually on Jessie and it will work again.
kweb itself works with any variant. If you want to add the same functionality (watch web video with omxplayerGUI) to Chromium, Firefox or Midory, you'll need the youtube-dl server.
In the kweb suite, youtube-dl is used to extract the name and real address of web video from a website. How long that takes, depends significantly on the installation method. Here are the timings on a RPi 3 for all solutions on Jessie and Stretch (where everything runs a bit slower):
Fake-Binary (all in one, contains a zip with all modules as text: .py)
time ./youtube-dl -f best -e -g
https://www.youtube.com/watch?v=aX8Li5ks3Kc
Stretch:
real 0m9.331s
user 0m8.400s
sys 0m0.110s
Jessie
real 0m8.085s
user 0m7.200s
sys 0m0.110s
git or pip installation (using pyc modules)
time youtube-dl -f best -e -g
https://www.youtube.com/watch?v=aX8Li5ks3Kc
Stretch:
real 0m5.712s
user 0m4.790s
sys 0m0.150s
Jessie:
real 0m4.650s
user 0m3.780s
sys 0m0.160s
Using the youtube-dl server
time wget -q -O -
http://127.0.0.1:9192/info?url=https:// ... X8Li5ks3Kc
Stretch:
real 0m1.663s
user 0m0.010s
sys 0m0.000s
Jessie:
real 0m1.351s
user 0m0.010s
sys 0m0.000s