It seems Wordpress is doing an exceptionally bad job when it comes to re-sizing my images.

In the media options I have set my image sizes to my liking. Most notably 857px wide for the medium thumbs, and set the quality to 100, as well as turned on sharpening.

I have set the following in the functions.php

add_filter( 'jpeg_quality', create_function( '', 'return 100;' ) );

Sadly this has little to no affect at all on the quality of the images produced in Wordpress.

wordpress resized original exported in lightroom to same resolution

At first the difference might not appear to be that distinct, but look at the rock? It's probably more apparent on photos with more detail, but it can still be seen here.

  • not sure what is it that you are comparing here – Mark Kaplun Jul 15 '16 at 16:19

The filter you are using only stops jpeg compression. This does not prevent quality loss when resizing an image. Manually you would apply a sharpen filter afterwards to regain some crispyness in the image. WordPress doesn't do that.

However, WP does have the WP_Image_Editor class for image manipulation. It has some built-in methods, such as resize and rotate, but no sharpen. However, the class also gives a gateway to PHP's ImageMagick library, which allows you to sharpen images.

To cut a long story short, someone has already done this for you and made it into a plugin.

  • the actual code in there should fit an answer ;) – Mark Kaplun Jul 15 '16 at 17:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.