mirror of
https://github.com/nextcloud/server.git
synced 2026-02-03 20:41:22 -05:00
chore(Preview): Remove avconv support
Signed-off-by: provokateurin <kate@provokateurin.de>
This commit is contained in:
parent
4111bdbbcf
commit
4b2a93cf0a
4 changed files with 5 additions and 16 deletions
|
|
@ -1429,7 +1429,7 @@ $CONFIG = [
|
|||
/**
|
||||
* Custom path for ffmpeg binary
|
||||
*
|
||||
* Defaults to ``null`` and falls back to searching ``avconv`` and ``ffmpeg``
|
||||
* Defaults to ``null`` and falls back to searching ``ffmpeg``
|
||||
* in the configured ``PATH`` environment
|
||||
*/
|
||||
'preview_ffmpeg_path' => '/usr/bin/ffmpeg',
|
||||
|
|
|
|||
|
|
@ -135,12 +135,7 @@ class Movie extends ProviderV2 {
|
|||
|
||||
$binaryType = substr(strrchr($this->binary, '/'), 1);
|
||||
|
||||
if ($binaryType === 'avconv') {
|
||||
$cmd = [$this->binary, '-y', '-ss', (string)$second,
|
||||
'-i', $absPath,
|
||||
'-an', '-f', 'mjpeg', '-vframes', '1', '-vsync', '1',
|
||||
$tmpPath];
|
||||
} elseif ($binaryType === 'ffmpeg') {
|
||||
if ($binaryType === 'ffmpeg') {
|
||||
if ($this->useHdr($absPath)) {
|
||||
// Force colorspace to '2020_ncl' because some videos are
|
||||
// tagged incorrectly as 'reserved' resulting in fail if not forced.
|
||||
|
|
|
|||
|
|
@ -373,14 +373,11 @@ class PreviewManager implements IPreview {
|
|||
|
||||
$this->registerCoreProvidersOffice();
|
||||
|
||||
// Video requires avconv or ffmpeg
|
||||
// Video requires ffmpeg
|
||||
if (in_array(Preview\Movie::class, $this->getEnabledDefaultProvider())) {
|
||||
$movieBinary = $this->config->getSystemValue('preview_ffmpeg_path', null);
|
||||
if (!is_string($movieBinary)) {
|
||||
$movieBinary = $this->binaryFinder->findBinaryPath('avconv');
|
||||
if (!is_string($movieBinary)) {
|
||||
$movieBinary = $this->binaryFinder->findBinaryPath('ffmpeg');
|
||||
}
|
||||
$movieBinary = $this->binaryFinder->findBinaryPath('ffmpeg');
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -26,10 +26,7 @@ class MovieTest extends Provider {
|
|||
|
||||
protected function setUp(): void {
|
||||
$binaryFinder = Server::get(IBinaryFinder::class);
|
||||
$movieBinary = $binaryFinder->findBinaryPath('avconv');
|
||||
if (!is_string($movieBinary)) {
|
||||
$movieBinary = $binaryFinder->findBinaryPath('ffmpeg');
|
||||
}
|
||||
$movieBinary = $binaryFinder->findBinaryPath('ffmpeg');
|
||||
|
||||
if (is_string($movieBinary)) {
|
||||
parent::setUp();
|
||||
|
|
|
|||
Loading…
Reference in a new issue