git.shiar.nl
/
minimedit.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f8288b7
)
thumb: flatten transparent images to white background
author
Mischa POSLAWSKY
<perl@shiar.org>
Fri, 12 Jul 2019 00:33:50 +0000
(
02:33
+0200)
committer
Mischa POSLAWSKY
<perl@shiar.org>
Fri, 12 Jul 2019 02:18:16 +0000
(
04:18
+0200)
Ensure consistent background for some SVG and PNG originals.
thumb/index.php
patch
|
blob
|
history
diff --git
a/thumb/index.php
b/thumb/index.php
index 27a194ee51584f5840c42eff880207e02e6a42da..f15a180b1e8e89983eea66d5430f7ee7fc19e159 100644
(file)
--- a/
thumb/index.php
+++ b/
thumb/index.php
@@
-89,6
+89,7
@@
function mkthumb_exec($source, $target, $width, $height)
$cmd = implode(' ', array_map('escapeshellarg', [
'convert',
'-trim',
+ '-background', 'white', '-layers', 'flatten',
'-resize', "${width}x${height}",
'-quality', '90%',
$source, "jpg:$target"