-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Description
Hi all, I've been looking at vips_resize(), the vips function that sharp uses for downsizing, and I think I've maybe found a couple of things which can improve quality, especially for small downsizes. Would anyone be able to help test the changes?
Code changes in this commit:
There's a test image here, plus sample shrinks from vipsthumbnail and convert. Put the images in separate tabs and try flipping between them.
http://www.rollthepotato.net/~john/skin/
The test image is an interesting one since it combines fine, high-contrast detail in the hair, plus a strong skin texture (I hope the subject doesn't mind me saying that). The downsize needs to minimise aliasing in the hair while retaining texture in the skin.
The old vips_resize() avoided anti-aliasing nicely, but had the effect of almost airbrushing the skin. The three changes in the patch:
- reduce the strength of the anti-alias filter slightly
- does not do the final sharpening pass if we skipped the anti-alias filter
- fixes a bug where the sharpening would be skipped if there was no box filter
Any thoughts? Would someone be able to compare to photoshop? I remember we had an interesting discussion the last time we went over this code.