Page MenuHomePhabricator

provide thumb option to do sharpening on scaled images on a case by case basis
Open, LowestPublicFeature

Description

PNG thumbs are unsharp and there's nothign to do about when you want the thumbs in PNG format:

https://bugzilla.wikimedia.org/show_bug.cgi?id=29659
https://bugzilla.wikimedia.org/show_bug.cgi?id=6205
https://bugzilla.wikimedia.org/show_bug.cgi?id=726

What about an option to return PNG thumbs in JPG (if source is not transparent)?

JPG thumbs of PNG are def sharper. compare yourself: http://www.mediawiki.org/wiki/User:Subfader/PNG_thumbs_unsharp


Version: 1.21.x
Severity: enhancement

Details

Reference
bz37960

Event Timeline

bzimport raised the priority of this task from to Lowest.Nov 22 2014, 12:28 AM
bzimport set Reference to bz37960.
bzimport added a subscriber: Unknown Object (MLST).

I imagine that has less to do with the file format and more to do with the fact we use image magick to increase sharpening of jpeg files, but not png files.

PNG is generally used for line art, where you don't want to sharpen things artificially (from what I understand).

Note: tiff is sharpened as well (I believe anyhow).

You're right. Photoshop saves the original PNG in smaller size as sharped image.

So all we need is an option to sharp the thumbs.

[[File:Foo.png|250px|sharpen]]

Add a global option to make it default (see reasons below, not every wiki is Wikipedia):

$wgImageMagickSharpenPNGthumbs = true;

option to override that: [[File:Foo.png|250px|nosharpening]]

You shouldn't assume what type of images which format is used for. PNG is also used a lot for artwork, esp when it has plain pink or red (JPG has horrorible artefacts on these).

Also, my wiki doesn't use line art images. For me most PNG images are normal images. I archive images from web so I take them in the format as they come. I won't convert the PNG source files to JPG just to make their thumbs sharper.

Changing bug title per your last comment.

PNG is generally assumed to be line art since that's what the format is optimized for (Or i thought anyways. I'm not an image expert so I could have that all wrong).

It doesn't matter what the format is ment to be for if the web uses it as lossless and bug-free alternative to JPG.

As said, I don't have line art images on my wiki and 99% of my PNG files are normal images. All their thumbs are unsharp. The reason why they're unsharp is that MediaWiki doesn't want to sharp them since they are better should be line-art? Shame on these images for not being line art :D

Aklapper changed the subtype of this task from "Task" to "Feature Request".Feb 4 2022, 11:14 AM
Aklapper removed a subscriber: wikibugs-l-list.