Skip to main content

Timeline for Image quality based on image size

Current License: CC BY-SA 3.0

9 events
when toggle format what by license comment
Apr 3, 2014 at 16:27 history bounty ended CommunityBot
Mar 28, 2014 at 22:52 comment added Otto Regenerating might work too, if it resaves the image. No code is going to change existing files on the system without you actually taking the action to reload and resave them.
Mar 28, 2014 at 9:44 comment added nocksock Hm. So basically it only gets fired on initial upload? Is there a filter that gets called when thumbnails are regenerated (eg with the Regenerate Thumbnail Plugin)?
Mar 28, 2014 at 0:13 comment added Otto The image_editor_save_pre filter gets called just before it saves the image, in the image editor. You have to use the image editor to have that function get invoked.
Mar 27, 2014 at 10:56 comment added nocksock It seems to me that image_editor_save_pre doesn't get called. When I try to output stuff using error_log (which definitely works) I don't get any output. :/
Mar 27, 2014 at 7:57 comment added kaiser I assumed it would save in between. Thanks for the heads up.
Mar 27, 2014 at 2:57 comment added Otto The quality is an exact value, not a percentage. You can set and reset it all you like, until it saves. Setting it to 10 a hundred times leaves it at 10.
Mar 26, 2014 at 17:37 comment added kaiser Reason why I didn´t use something as straight as this one (+1) is, that I remember vaguely that when editing some image (rotating, cropping, etc.), every action was called twice, reducing the quality two times. Still the "is an instance of WP_Image_Editor" part is a much more of a solution than what I wrote.
Mar 26, 2014 at 16:57 history answered Otto CC BY-SA 3.0