https://bugzilla.wikimedia.org/show_bug.cgi?id=47311
Tim Starling <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |[email protected] --- Comment #3 from Tim Starling <[email protected]> --- (In reply to comment #0) > VipsScalar currently works by running a series of separate vips commands. > Looking at the source here: > > https://gerrit.wikimedia.org/r/gitweb?p=mediawiki/extensions/VipsScaler.git; > a=blob;f=VipsScaler_body.php;h=69f31b108d99849c36fd92591f135bfbfca69d02; > hb=HEAD > > makeCommands() will typically run something like: > > # unpack png file to a huge disc temp > vips im_png2vips huge.png t1.v It only does this if the "preconvert" option is set, which it isn't. > # block shrink by large integer factor > vips im_shrink t1.v t2.v xx xx > # bilinear resize to final exact dimensions > vips im_resize_linear t2.v t3.v xxxx yyyy I don't know where you're getting this from. It either does im_shrink by a precise floating point factor, giving the exact dimensions required, or it does im_resize_linear, it can't do both. In the case of PNGs, it is configured to use im_shrink. > # sharpen slightly to counteract softening effect of bilinear > vips im_convf t3.v t4.v sharpen_matrix No, the sharpening counteracts for the reduction in the acutance perception of the human eye at smaller angular sizes. It's necessary regardless of how you scale the image. Have a look at the sample images I attached to bug 23258. > # any 90-degree rotation required > vips im_rotxx t4.v final.jpg > > Instead, it should simply run vipsthumbnail: > > vipsthumbnail huge.png -o final.jpg --size required-output-size-in-pixels > --interpolator bicubic I said on bug 25990 comment 9 that the reason we can't use vipsthumbnail is because it stores the uncompressed source image on disk. It may be that this is no longer the case, however, using vipsthumbnail would still mean giving up control over the sharpening parameters. -- You are receiving this mail because: You are the assignee for the bug. You are on the CC list for the bug. _______________________________________________ Wikibugs-l mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikibugs-l
