Sharpen filter bookmarklet

Joined
Jul 9, 2018
Messages
24
Some manga (like https://mangadex.org/title/13318/dagashi-kashi) have relatively small pages that just become blurry upon zooming out with your browser.

I made (read: shamelessly copied from StackOverflow) a JavaScript Bookmarklet to sharpen all images in the current page. I think it may be useful for some.

To use it, just make new bookmark and paste this into the location field:

Code:
javascript:(function(){document.body.insertAdjacentHTML( 'beforeend', '<svg><filter id="sharpen"><feConvolveMatrix order="3" preserveAlpha="true" kernelMatrix="-0.0625 -0.125 -0.0625 -0.125 1.75 -0.125 -0.0625 -0.125 -0.0625"/></filter></svg>');var imgs = document.getElementsByTagName("img");for (var i = 0; i < imgs.length; i++) {imgs[i].style.filter = "url(#sharpen)";}})();

and click on the bookmark whenever you need to sharpen the images.

Sample

Before (1.2x zoom):
pvxBgT4.png


After (1.2x zoom):
7mg0Jun.png


The script only affect what is displayed in the browser: if you save the image, it won't have sharpen filter applied on it.

I'm currently use Adaptive unsharp masking as sharpeninig filter:
eTcymY4.png


If you know a better one, feel free to share.
 

Users who are viewing this thread

Top