Hi Horst,
I reviewed most of your changes and integrated them:
->optimize now accepts an array options so you can customize behavior per call
->optimize won't overwrite original files, a variation would be created
->optimize will overwrite a variation
I had a look at passing the options to size() with the purpose of them getting passed on to this module, but it seems that if the options aren't the usual ones used by ImageSizer they get discarded, so I can't read them - which is a bummer. Do you know of a way around that? Or maybe that's changed in the dev branch?
Also regarding setting the quality to 100 before imagesizer runs if the optimizer would be used later - that would be awesome but I don't see a hook for that - do you have any thoughts on that?