• Hello,
    This may not be the right forum for my question but I think someone may be able to point me in the right direction.

    In my designs I use a lot of large and full screen images. For a decent resolution compromise I will take the time to edit and compress these big image files through photoshop. So it’s discouraging when the WordPress compression results in images (which are larger than than my original) for use in smaller viewports.

    For instance, a own 200kb, 1920×1080 img.jpg initiates the WP creation of: img-1600×750.jpg which weighs in at over 400kb. And this same discouraging ratio of WP compression happens regularly.

    The end goal is to use my own (lighter weight) small image for the smaller viewport.

    Thank you..

    https://wordpress.org/plugins/ricg-responsive-images/

Viewing 14 replies - 1 through 14 (of 14 total)
  • Plugin Contributor Joe McGill

    (@joemcgill)

    Hi letssgo,

    We’ve noticed the same problem, and are trying to help fix this by improving the compression settings in WordPress itself. Would you mind trying out the advanced image compression setting in this plugin by adding the following to your theme’s functions.php file?

    function load_advanced_image_compression() {
        add_theme_support( 'advanced-image-compression' );
    }
    add_action( 'after_setup_theme', 'load_advanced_image_compression' );

    Thanks,
    Joe

    Thread Starter letsssgo

    (@letsssgo)

    Very glad to hear there may be solutions in the works. Anything I can do to help please let me know. I will add the above code today and let you know.

    Thank you,
    Steve

    Thread Starter letsssgo

    (@letsssgo)

    Joe, I put your code into the bottom of my theme’s function.php. Also tried without any plugins activated. No change in the compression ratios. Same test in twentysixteen with the same results.

    The only difference between the two themes:
    Kalium spit out 16 jpgs, including the original.
    Twentysixteen spit out five. For me that’s a whole other issue for another day.

    Would you care to see the images of the output?

    Plugin Contributor Joe McGill

    (@joemcgill)

    Hi Steve,

    Sounds like your server might not have ImageMagick support, which is required for our changes to have any affect. Some servers only support GD for image manipulation.

    Here are some options for testing for Imagick support on your server:
    http://stackoverflow.com/questions/4208253/verify-imagemagick-installation

    Joe

    Thread Starter letsssgo

    (@letsssgo)

    Ok, thanks. Checking..

    Thread Starter letsssgo

    (@letsssgo)

    Joe, my server seems to be using ImageMagick version: 6.3.3 03/08/07
    Here’s the test page: http://www.demo44.com/ImageMagick.php
    I was asked if you are using the path: /usr/local/lib/ImageMagick

    Thread Starter letsssgo

    (@letsssgo)

    standin by.

    Plugin Contributor Joe McGill

    (@joemcgill)

    Hi Steve,

    Could you let me know what the following function outputs?

    var_dump( _wp_image_editor_choose() );

    It should return WP_Image_Editor_Imagick if PHP is configured to use Imagick on your server. Otherwise, it will probably say WP_Image_Editor_GD. If the latter, then the advanced image compression in our plugin won’t have any affect.

    Joe

    Thread Starter letsssgo

    (@letsssgo)

    Nothing returned. I’m beginning to believe that it’s time for a new host. Not much support.

    Thread Starter letsssgo

    (@letsssgo)

    Hi Joe, I did get a response from a hosting tech who said:

    “It looks like the proper path is not used for ImageMagick. So, it is showing as disabled. I suggest that you use /usr/bin/resize or /usr/local/bin/convert depending on your need. Please define this path in the script and see whether it says that ImageMagick is disabled.
    If the issue persists get back with script URL and steps to duplicate the issue so that we can check further.”

    Please let me know your thoughts.

    Plugin Contributor Joe McGill

    (@joemcgill)

    Hey Steve,

    We don’t actually define the path to ImageMagick at all. Instead, we use whatever WordPress has access to by default. On your host, the ImageMagick must be in the path that is used by the user account that runs PHP.

    Joe

    Thread Starter letsssgo

    (@letsssgo)

    Joe, just to be sure, is Imagemagick required for any RICG Responsive capabilities to work? Is there documentation on how to find and set up the handshake between Imagemagick and WordPress? How would I find what WordPress has access to by default?
    Thank you, Steve

    Plugin Contributor Joe McGill

    (@joemcgill)

    Hi Steve,

    Imagemagick is only required for the advanced image compression settings to work, everything else will work fine as long as there is another image library available (like GD) so WordPress can create alternate sizes of images that you upload to the media library. If neither GD nor Imagemagick are installed on your host then this plugin won’t do anything.

    Joe

    Thread Starter letsssgo

    (@letsssgo)

    Hi Joe,

    I’m in the process of looking for a decent hosting provider that supports ImageMagick.

    Is there documentation as to hoe the advanced image compression works? My hope is to be able to use my own, originally compressed images. I work hard to make them right. Would I be able to point to the desired image with the srcset functionality? How does it choose the image?

    Steve

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘Compression and working with full screen images in WordPress.’ is closed to new replies.