Generate thumbnails based on buckets
authorGilles Dubuc <gdubuc@wikimedia.org>
Tue, 3 Jun 2014 16:09:30 +0000 (18:09 +0200)
committerGergő Tisza <tgr.huwiki@gmail.com>
Tue, 8 Jul 2014 20:03:38 +0000 (20:03 +0000)
commit7036e7b68d4165e14d43fb34f80556af7a68f95b
tree63ccca9d03b5755bbf57c526c4651ece0d452990
parentfa529fb23a0007a3b28aba1d8c9a0d261cea4dd2
Generate thumbnails based on buckets

Instead of always generating thumbnails based on the original,
this adds the ability to generate thumbnails based on
references buckets. The buckets themselves have their
generation chained following the same process (smaller bucket
generated based on bigger bucket). In situations where no
suitable bucket is found, the original is used, like it used to.

This is entirely optional, as most non-WMF wikis would probably prefer
to keep generating all thumbnails based on originals.

The quality implications have been verified through a survey
aimed at Commons users and people actually preferred the chained version.
Presumably due to the multiple passes of sharpening which maintained
visual details better for small thumbnail sizes.

Change-Id: I285d56b2024c81365247338f85c1e0aa708cb21e
Mingle: https://wikimedia.mingle.thoughtworks.com/projects/multimedia/cards/600
Bug: 67525
includes/DefaultSettings.php
includes/filerepo/file/File.php
includes/media/Bitmap.php
includes/media/ImageHandler.php
includes/media/Jpeg.php
includes/media/MediaHandler.php
includes/media/PNG.php
tests/phpunit/includes/filerepo/file/FileTest.php [new file with mode: 0644]