Open greathappyforest opened 6 years ago
Hi! No there is no extra conf, MediaDownloader only checks if post_processor is actually installed, and youtube-dl should auto-detect it. Does MediaDownloader prevent you to start your download or MediaDownloader actually downloads but unwanted quality?
Actually, I installed the MediaDownloader with the docker, and 'ffmpeg', youtube-dl and MediadDownloader are in the same container. However, when I trying to download the higher quality than 720p. The best option combine video and audio are always returned 720p videos, but I can see and download higher quality video or audio separately in the direct download.
root@vps:~# docker exec -it 74a0c bash
root@74a0c93ef457:/# ls
bin dev home lib64 mnt proc run selinux sys usr www
boot etc lib media opt root sbin srv tmp var
root@74a0c93ef457:/# cd www
root@74a0c93ef457:/www# ls
youtube-dl
root@74a0c93ef457:/www# cd youtube-dl/
root@74a0c93ef457:/www/youtube-dl# ls
COPYING config download.php index.php js list.php logout.php
LICENSE css downloads init.php lib login.php
root@74a0c93ef457:/www/youtube-dl# ffmpeg
ffmpeg version 3.4-static http://johnvansickle.com/ffmpeg/ Copyright (c) 2000-2017 the FFmpeg developers
built with gcc 6.4.0 (Debian 6.4.0-7) 20170920
configuration: --enable-gpl --enable-version3 --enable-static --disable-debug --disable-ffplay --disable-indev=sndio --disable-outdev=sndio --cc=gcc-6 --enable-fontconfig --enable-frei0r --enable-gnutls --enable-gray --enable-libfribidi --enable-libass --enable-libvmaf --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librubberband --enable-librtmp --enable-libsoxr --enable-libspeex --enable-libvorbis --enable-libopus --enable-libtheora --enable-libvidstab --enable-libvo-amrwbenc --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxvid --enable-libzimg
libavutil 55. 78.100 / 55. 78.100
libavcodec 57.107.100 / 57.107.100
libavformat 57. 83.100 / 57. 83.100
libavdevice 57. 10.100 / 57. 10.100
libavfilter 6.107.100 / 6.107.100
libswscale 4. 8.100 / 4. 8.100
libswresample 2. 9.100 / 2. 9.100
libpostproc 54. 7.100 / 54. 7.100
Hyper fast Audio and Video encoder
usage: ffmpeg [options] [[infile options] -i infile]... {[outfile options] outfile}...
Use -h to get full help or, even better, run 'man ffmpeg'
root@74a0c93ef457:/www/youtube-dl# youtube-dl
WARNING: Assuming --restrict-filenames since file system encoding cannot encode all characters. Set the LC_ALL environment variable to fix this.
Usage: youtube-dl [OPTIONS] URL [URL...]
youtube-dl: error: You must provide at least one URL.
Type youtube-dl --help to see a list of all options.
root@74a0c93ef457:/www/youtube-dl#
Please check my rep forks from your rep: https://github.com/greathappyforest/MediaDownloader
I'm not familiar with docker, but what I could suggest to you is to test directly youtube-dl from a terminal. Output will help to determine if problem is from youtube-dl or MediaDownloader.
youtube-dl -f bestvideo+bestaudio url_to_video
root@74a0c93ef457:/www/youtube-dl/downloads# youtube-dl -f bestvideo+bestaudio - -prefer-ffmpe https://www.youtube.com/watch?v=vr0qNXmkUJ8&t=117s
[1] 5923
root@74a0c93ef457:/www/youtube-dl/downloads# WARNING: Assuming --restrict-filena mes since file system encoding cannot encode all characters. Set the LC_ALL envi ronment variable to fix this.
[youtube] vr0qNXmkUJ8: Downloading webpage
[youtube] vr0qNXmkUJ8: Downloading video info webpage
[youtube] vr0qNXmkUJ8: Extracting video information
[youtube] vr0qNXmkUJ8: Downloading MPD manifest
[download] Destination: GoPro_HERO6_-_This_Is_the_Moment_in_4K-vr0qNXmkUJ8.f266. mp4
[download] 100% of 585.82MiB in 00:18
[download] Destination: GoPro_HERO6_-_This_Is_the_Moment_in_4K-vr0qNXmkUJ8.f140. m4a
[download] 100% of 4.12MiB in 00:00
[ffmpeg] Merging formats into "GoPro_HERO6_-_This_Is_the_Moment_in_4K-vr0qNXmkUJ 8.mp4"
Deleting original file GoPro_HERO6_-_This_Is_the_Moment_in_4K-vr0qNXmkUJ8.f266.m p4 (pass -k to keep)
Deleting original file GoPro_HERO6_-_This_Is_the_Moment_in_4K-vr0qNXmkUJ8.f140.m 4a (pass -k to keep)
[1]+ Done youtube-dl -f bestvideo+bestaudio --prefer-ffmpe h ttps://www.youtube.com/watch?v=vr0qNXmkUJ8
root@74a0c93ef457:/www/youtube-dl/downloads#
I think I got a k4 video download with youtube-dl inside docker. Can you check the parameter " --prefer-ffmpeg" correctly passing from frontend?
I sent you a PR for you to test. I'm about to publish MediaDownloader v1.0 (which is a total rework), so I won't publish a clean fix for this bug, but I hope it will help you to wait until new version get released!
Not work actually. I'm just wondering does ffmpeg works if running without docker? Can the new version running in the docker?
Actually, it does work with avconv which is the default post processor used by youtube-dl (auto-detected). I never test with ffmpeg, but I know some linux distributions install ffmpeg instead of avconv (when you're installing avconv) and only do a symlink from avconv to ffmpeg. In current official version (v0), there is no real support of post processors. In new version (v1, now in dev branch), support is planned but not integrated.
Can you try installing avconv in your docker ?
root@vps:/MediaDownloader/docker# docker exec fce587
"docker exec" requires at least 2 arguments.
See 'docker exec --help'.
Usage: docker exec [OPTIONS] CONTAINER COMMAND [ARG...] [flags]
Run a command in a running container
root@vps:/MediaDownloader/docker# docker exec -it fce587 bash
root@fce587d44417:/# ls
bin dev home lib64 mnt proc run selinux sys usr www
boot etc lib media opt root sbin srv tmp var
root@fce587d44417:/# cd www
root@fce587d44417:/www# ls
youtube-dl
root@fce587d44417:/www# cd youtube-dl/
root@fce587d44417:/www/youtube-dl# ls
COPYING config download.php index.php js list.php logout.php
LICENSE css downloads init.php lib login.php
root@fce587d44417:/www/youtube-dl# av
avconv avplay avprobe avserver
root@fce587d44417:/www/youtube-dl# av
avconv avplay avprobe avserver
root@fce587d44417:/www/youtube-dl# avconv
avconv version 0.8.21-6:0.8.21-0+deb7u1, Copyright (c) 2000-2014 the Libav devel opers
built on Oct 16 2017 15:36:54 with gcc 4.7.2
Hyper fast Audio and Video encoder
usage: avconv [options] [[infile options] -i infile]... {[outfile options] outfi le}...
Use -h to get full help or, even better, run 'man avconv'
root@fce587d44417:/www/youtube-dl# cd config/
root@fce587d44417:/www/youtube-dl/config# cat config.php
<?php
$CONFIG = array (
// Enable password restriction (boolean)
'security' => true,
// MD5 hash of choosen password. **********
'password' => '****************************',
// Relative folder (from MediaDownloader folder) where to store downloaded files. No need for trailing slash. (string)
'output_folder' => 'downloads',
// Prefered post processor between avconv or ffmpeg. (string)
'post_processor' => 'avconv',
// Maximum simultaneous server downloads limit. Set to 0 to disable limit. (integer)
'max_dl' => 9
);
?>
root@fce587d44417:/www/youtube-dl/config#
Just added avconv and tried. Post-processors was also not working with avconv in the docker.
Could be a docker integration issue (as I already said, I'm not a docker user). If you feel adventurous enough, you could try to install new version (v1b). This version would next allows you to add extra arguments to youtube-dl (such as post-processor path and preferences).
Currently, post processing does not work in v1b (cf #13 ) Thanks for your patience, I'm working on it.
I installed ffmpeg, and set up
'post_processor' => 'ffmpeg',
but it looks like not working on youtube-dl gui.Just wondering if there is any extra conf I didn't setup to enable ffmpeg?