Add a setting that controls ffmpeg verbosity

Don't display ffmpeg errors in tests
This commit is contained in:
Pierre Rudloff 2017-12-09 23:16:48 +01:00
parent 4ae585eef1
commit 959b141282
5 changed files with 14 additions and 1 deletions

View File

@ -89,6 +89,14 @@ class Config
*/
public $audioBitrate = 128;
/**
* avconv/ffmpeg logging level.
* Must be one of these: quiet, panic, fatal, error, warning, info, verbose, debug
*
* @var string
*/
public $avconvVerbosity = 'error';
/**
* YAML config file path.
*

View File

@ -276,7 +276,7 @@ class VideoDownload
$builder = ProcessBuilder::create(
[
$this->config->avconv,
'-v', 'error',
'-v', $this->config->avconvVerbosity,
//Vimeo needs a correct user-agent
'-user_agent', $this->getProp(null, null, 'dump-user-agent'),
'-i', $url,

View File

@ -18,6 +18,9 @@ convert: false
# Path to your avconv or ffmpeg binary
avconv: vendor/bin/ffmpeg
# avconv/ffmpeg logging level.
avconvVerbosity: error
# Path to your rtmpdump binary
rtmpdump: vendor/bin/rtmpdump

View File

@ -1,2 +1,3 @@
---
convert: false
avconvVerbosity: fatal

View File

@ -2,6 +2,7 @@
convert: false
python: C:\Python36\python.exe
avconv: C:\ProgramData\chocolatey\bin\ffmpeg.exe
avconvVerbosity: fatal
rtmpdump: C:\ProgramData\chocolatey\bin\rtmpdump
youtubedl: C:\Python36\Lib\site-packages\youtube_dl\__main__.py
params: