Quality of image compression

Michal created the topic: Quality of image compression

Dear,

I am playing with Photo Gallery and I have found, that it may be used also for optimization of images, which is very good possibility.
For example if I upload an image 1500 kB (1600x900px) and add the watermark, then it decreases to 1300 kB. Quality of compression seems good and no degradation is visible.
To reduce it more is possible to use the option "resize". When resized by only the one pixel to 1599x899px, then it decreases to 430 kB, which is great. But the quality is poor (not sharp).
I would need to keep the dimensions same 1600x900px and just reduce the kilobytes, but when I try to "resize" from 1600x900px to 1600x900px, then nothing happens of course.

I use another plugin for optimization of WordPress Media Library images and it allows to keep the dimensions and reduce just a quality. When that plugin reduces the same image to 400 kB, the quality is still good and sharp.

What compression tool is used in Photo Gallery and is there any way how to set its rate (e.g. in percents) to customize the quality?
Something between a "watermark reduction" and "resize reduction" would be ideal.

#84735

Please Log in or Create an account to join the conversation.


Agapi G. replied the topic: Quality of image compression

Hello Michal!

Thank you for posting your inquiry!

We discussed your notes with our development team, and they suggested a solution, which reduces the size of the images, but it does not damage the resolution. Please open /photo-gallery/admin/controllers/BWGControllerGalleries_bwg.php file, and find this code:

$image_quality = 90;


Please replace it with the following:

$image_quality = 100;


We will also include this in one of the next updates of the plugin.
Thanks! Have a nice start of the week!


Kind regards,
Agapi G.
Web-Dorado team
#84801

Please Log in or Create an account to join the conversation.


Michal replied the topic: Quality of image compression

Dear Agapi,

it would be great to include this in one of the next updates of the plugin! I very appreciate your effort to improve your products continuously.

Thank you for a solution. I have tried it. The quality can be customized by this way, but the resizing does not allow to keep the resolution full (nothing happens). It must be reduced at least by one pixel and then this option works and changes the set quality. But this manual way cannot be used in bulk for optimization, when each image has different resolution, which must stay the same.
I tried to use a watermarking without watermark in bulk, but it resized all images according to the General Options. Even all thumbnails or small images becomes larger and blur. A disaster. Luckily I had a backup, so I had to rewrite whole images directory via FTP.

Because your team is open to the improvements, in my opinion this has a big potential. You can get 2 in 1!
I mean a watermarking option in Photo Gallery plugin could be also an Image Optimizer! Just to add some new options and functionalities. It is already able to optimize, so it it would be very usefull to allow them in some user friendly settings menu.
Please, have a look at the attachment where are some options of my WordPress Media Library optimizer.


Especially scaling mode is very usefull, when you have different resolutions. Now with your current watermark if I set e.g. 10% size - it is good for a large image, but on small image the watermark is microscopic. So the option "none" keeps just one size of watermark and the other scaling modes (fill, fit etc.) add more options for users.
More possible functionalities of "watermarking/optimization" are here for your inspiration: wordpress.org/plugins/easy-watermark/screenshots/

So, if you would be willing to allow(access) some existing options and add some more, that would be amazing!
Your plugin would obtain a massive extension and would be much better then competitors. And needless to say how important is an optimization of images for SEO and fast loading of sites.
I am looking forward to the next updates, if your team will add something of that. :)

Thanks and have a nice day!

#85065
Attachments:

Please Log in or Create an account to join the conversation.


Michal replied the topic: Quality of image compression

Dear,
as you suggested, I have tried to open /photo-gallery/admin/controllers/BWGControllerGalleries_bwg.php file, and find that code:
$image_quality =

I found it twice for a .jpg format:
Row #317: $image_quality = 100;
and
Row #816: $image_quality = isset($wd_bwg_options->jpeg_quality) ? $wd_bwg_options->jpeg_quality : 75;

If "100" means, that the quality is already set to maximum, then I would expect no change of the size. But when I set a watermark for a file 1,8 MB, then I have got a watermarked file 1,5 MB with a bit shifted red-channel. It seems that a watermarking reduces the size (MB) approx by 10% down, but where is it set? I cannot to find where is that $image_quality = 90; as you mentioned.

Thank you

#85165

Please Log in or Create an account to join the conversation.


Agapi G. replied the topic: Quality of image compression

Hi Michal!

Firstly, regarding your previous post, unfortunately we don't have plans to create image optimization options yet. But we would love to do that in the future. So could you please post your idea to our Submit your idea page?

Users can vote, and our development team will consider working on this for further releases of Photo Gallery plugin.

As for your second question, looks like you are looking at the version, where this has already been changed. Our developers have included the change we suggested in the latest version. Could you please let us know what are you trying to modify?

Thanks! Have a great start of the week!


Kind regards,
Agapi G.
Web-Dorado team
#85205

Please Log in or Create an account to join the conversation.


Michal replied the topic: Quality of image compression

Dear Agapi,
thanks for offer to submit my idea, I will do it.

My current version is 2.3.33. Your developers installed and customized it for me last week, because another problem, if you remember.
I cannot see an option to set the quality of the optimization in this version.
I tried what your developers suggested bellow, but as I described, it does nothing.

Your plugin already optimizes images in 2 ways:
1) When resize an image
2) When set a watermark

1) is not good for me, because each my image has a different resolution which I need to keep. The resizing tool changes them according to General Options, so it cannot be used in bulk.
2) a watermarking keeps the resolution and just adds a watermark, which is what I need.
But it defaultly reduces a quality by 10% approx. And what I need is to control this rate.

Thank you

#85309

Please Log in or Create an account to join the conversation.


Agapi G. replied the topic: Quality of image compression

Hi Michal!

Firstly please note, that I was not mentioning to quality options, but the $image_quality = 90; code instead. Options are not available, I meant, that this code was modified in latest version, so that's why you cannot find it.

Could you please let us know if the quality, that lowers, refers to thumbnail images or the large ones? Also, are they .png formatted images, or .jpg?
Thanks! Have a nice day!


Kind regards,
Agapi G.
Web-Dorado team
#85381

Please Log in or Create an account to join the conversation.


Michal replied the topic: Quality of image compression

Dear Agapi,

you have probably skipped my message #85165 three days ago. Please, read it, I described everything there.

I confirm again, that I spent hours of testing the watermarks and changing the $image_quality = 90; code, but as I mentioned, there is defaultly $image_quality = 100; on the line #317.
When I try to change 100 for example to 70 or 50 or 20 etc., it does nothing. The size (not the resolution) is always reduced from 1,8MB image to 1,5MB. Which is about 10% lower.
I work with originals, not thumbnails. And obviously only with .JPGs. After each attempt, I rewrite via FTP a tested image with original and test again.
Also I found additional lines for .JPGs, tried change them as well, but nothing happens.
The original image is always reduced approx by 10% down like before tests. Even when I add a watermark .PNG 1x1px transparent. Which is in fact "no watermark", so an image should be absolutely the same as before addition. The resolution is the same, just the quality drops down by those 10%. This is fine for an ability to optimize images with or without a watermark. But I still cannot control those 10% and change them.
That's what I write about all the time.
Thank you.

#85465

Please Log in or Create an account to join the conversation.


Agapi G. replied the topic: Quality of image compression

Hi Michal!

Could we please take a look at this from WordPress admin dashboard of your website? We had this access, and also FTP account, could you please reopen them with the same usernames and passwords?

Let me know when you make these changes, so our developers can start working.
Thank you! Have a good day!


Kind regards,
Agapi G.
Web-Dorado team
#85525

Please Log in or Create an account to join the conversation.


Michal replied the topic: Quality of image compression

Hi Agapi,
I refeshed the access details.
I have tried everything once again to make sure I did not a mistake and yes, when I change that code $image_quality = 100; (line #317), nothing happens. When I add a watermark to the image 1,8MB, after watermarking it grows up to 5,2MB (!) This is even worse than before. Before I got 1,5MB. So, I am really confused, how to control the image quality when adding a watermark.
When your developers will test it, please, do not set watermarks in bulk! I have created for them a gallery: TEST PHOTOS and a folder: gallery/TEST-PHOTOS with one test image. They can set a watermark individually only to this image and play with it as they need, but please not with the other ones. Thank you.

#85773

Please Log in or Create an account to join the conversation.


Agapi G. replied the topic: Quality of image compression

Hey Michal!

Thank you for reopening the access! I have asked our developers to check the issue. They will figure out a solution as soon as possible. I'll keep you posted with the progress they make.

Cheers!


Kind regards,
Agapi G.
Web-Dorado team
#85813

Please Log in or Create an account to join the conversation.


Agapi G. replied the topic: Quality of image compression

Hi Michal!

The reason that the watermark enlarged the size of the images, is that the image quality was switched to 100. Our development team has set it to 75 and tested on your images. The resolution does not drop.

We will add an option to control the quality of the images. But please use the gallery with this customized state until then.
Thank you! Have a great day!


Kind regards,
Agapi G.
Web-Dorado team
#85909

Please Log in or Create an account to join the conversation.


Time to create page: 0.895 seconds
Powered by Kunena Forum

WORLD-CLASS SUPPORT

We are here for you every step of the way. Turn to our support with any questions you might have about our products and services. Our experienced customer care team is available to help you as fast as we possibly can.

Contact us