Skip to content

Commit

Permalink
Use "mp4" as ImageMagick video format specifier
Browse files Browse the repository at this point in the history
We used to use "mpeg" which was the name of the ImageMagick coder being
used, but they've changed it to "video." "mp4" is supported by both old
and new versions.

(fix omeka#1841)
  • Loading branch information
zerocrates authored and ThibaudGLT committed Jan 3, 2023
1 parent 244683d commit 5d594aa
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion application/src/File/Thumbnailer/ImageMagick.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public function create($strategy, $constraint, array $options = [])
$mediaType = $this->sourceFile->getMediaType();
$origPath = sprintf('%s[%s]', $this->source, $this->getOption('page', 0));
if (strpos($mediaType, 'video/') === 0) {
$origPath = 'mpeg:' . $origPath;
$origPath = 'mp4:' . $origPath;
}

switch ($strategy) {
Expand Down
2 changes: 1 addition & 1 deletion application/src/File/Thumbnailer/Imagick.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public function create($strategy, $constraint, array $options = [])
$mediaType = $this->sourceFile->getMediaType();
$origPath = sprintf('%s[%s]', $this->source, $this->getOption('page', 0));
if (strpos($mediaType, 'video/') === 0) {
$origPath = 'mpeg:' . $origPath;
$origPath = 'mp4:' . $origPath;
}

try {
Expand Down

0 comments on commit 5d594aa

Please sign in to comment.