WordPress.org

Ready to get started?Download WordPress

Forums

Sharpen Resized Images
Examples (14 posts)

  1. Unsal Korkmaz
    Member
    Plugin Author

    Posted 2 years ago #

    Some users want to control amount of sharpening so i put some filters to plugin.

    Here is example:
    http://unsalkorkmaz.com/ajx-sharpen-resized-images/

    This is default settings that coming with plugin:

    add_filter('sharpen_resized_corner',function(){ return -1.2; });
    add_filter('sharpen_resized_side',function(){ return -1; });
    add_filter('sharpen_resized_center',function(){ return 20; });

    You can play with those numbers if u want to control amount of sharpening but default settings are optimal in my opinion.

    http://wordpress.org/extend/plugins/sharpen-resized-images/

  2. Unsal Korkmaz
    Member
    Plugin Author

    Posted 2 years ago #

    1 side note:

    If you are not using php5.3+, the code example above wont work for you. Here is what you can use:

    add_filter('sharpen_resized_corner','sharpen_resized_corner');
    function sharpen_resized_corner(){ return -1.2; }
    
    add_filter('sharpen_resized_side','sharpen_resized_side');
    function sharpen_resized_side(){ return -1; }
    
    add_filter('sharpen_resized_center', 'sharpen_resized_center');
    function sharpen_resized_center(){ return 20; }
  3. rucativava
    Member
    Posted 2 years ago #

    Unsal,
    Thank you for adding this functionality. So the way to adjust sharpening is through tinkering those 3 numbers? Is there a way to choose a number in a 0-10 scale?

  4. Unsal Korkmaz
    Member
    Plugin Author

    Posted 2 years ago #

    well..
    nope..
    thats all settings you need but there is no 0-10 scale settings tbh.
    I did some tests on those numbers here:
    http://unsalkorkmaz.com/ajx-sharpen-resized-images/

    You can play with those too if u want.

  5. southcast
    Member
    Posted 1 year ago #

    I was hopeful that this would work if i regenrated all the thumbnails. Sadly it didn't. Can you do some code-magic to get this to work if thumbnails are regenerated.
    It is a must have plugin for those whose business mainly relies on graphics, like mine. Thanks for the contribution.

  6. Unsal Korkmaz
    Member
    Plugin Author

    Posted 1 year ago #

    I didnt try but maybe you can use http://wordpress.org/extend/plugins/regenerate-thumbnails/
    plugin for previous photos.

    Edit: Yes, i tried and it works :)

  7. southcast
    Member
    Posted 1 year ago #

    well..your plugin just became priceless i guess. I tried the regeneration again and it totally worked !! This is amazing and your support is awesome. You got my vote of confidence !
    THANK YOU @unsalkorkmaz.

  8. southcast
    Member
    Posted 1 year ago #

    I suggest you put this bit into your description. People like me are bit clueless at first. This plugin is one of a kind i wish a lot of people will find this useful. Thanks again.

  9. Unsal Korkmaz
    Member
    Plugin Author

    Posted 1 year ago #

    Yeah, i should write this in description.
    No problem for help :)

  10. aurelm@gmail.com
    Member
    Posted 1 year ago #

    Hello.
    First thanks for the plugin, I was looking for a way to add sharpening to my wordpress blog photos.

    Howver I noticed that this lokks like it's resharpening allready compressed images instead of intercepting wordpress own pipeline. Is there any way to have sharper images without losing quality ?

    Thanks
    -Aurel

  11. Unsal Korkmaz
    Member
    Plugin Author

    Posted 1 year ago #

    Normally WordPress's default jpeg quality is 90. If you dont want any quality lost, you can set this to 100.

    if you using higher then php 5.3 you can use this:

    add_filter('jpeg_quality', function($quality) { return 100; } );

    or if you dont use php 5.3+ or if you dont know which version of php you using, you can use this:

    add_filter( 'jpeg_quality', 'jpeg_full_quality' );
    function jpeg_full_quality( $quality ) { return 100; }

    I need to warn about image sizes will be much bigger but probably you expect that right?

    IF you dont know where to add this code, there is an example article to give an idea:
    http://wp-events-plugin.com/tutorials/how-to-safely-add-php-code-to-wordpress/

  12. Geleosan
    Member
    Posted 1 year ago #

    Hi! Thax for you plugin!

    You say it is no scale 1-10. Could you explain what does number of this settings mean? I tried to set different numbers but i did not understand what was channged... So we have three parametrs of sharping: corner, center and side. But how can we control it?

  13. Unsal Korkmaz
    Member
    Plugin Author

    Posted 1 year ago #

    The real question here is
    "why dont you happy with default sharpening settings?"
    If you are happy, just leave it. You really dont need to change it. Its a balanced setting that %99 will satisfy you.

    If you are not happy with sharpening level and really want to learn everything about php sharpening, you can google "php imageconvolution".

  14. Geleosan
    Member
    Posted 1 year ago #

    Ok, thanx.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.