Most file-save plug-ins share a behavior inherited from other plug-ins:
they save and retrieve their last values so that invoking them again
will use the same parameters.  As discussed previously, this behavior
is fine for image filters but leads to annoying consequences for file
plug-ins: if you set some parameters when saving a file, then the same
parameters will be re-used if you save another (unrelated) file with
the same file format during that GIMP session.  These settings will be
used instead the default values normally set by the plug-in (which may
be user-configurable, as in the PNG and JPEG plug-ins).

Today, Jakub Friedl reported in #gimp that this behavior can lead to
surprising results, especially after the changes in the JPEG plug-in
that ensure that the initial quality level for the JPEG save dialog is
at least as good as the one from the original image.  Because all
settings from the JPEG plug-in (including the quality level) are
re-used from one file to the next, the net result is that the quality
level always increases if you load and re-save many files that were
originally saved with different quality levels.

Of course I could just add a quick workaround and change the code that
sets the initial quality level so that it ignores the value coming from
the "jsvals".  But wouldn't it be better to remove the call to
gimp_get_data (SAVE_PROC, &jsvals) and ignore all these values?  Is
there still a reason to keep these shared settings, considering that
each image that has been saved at least once gets its own
"jpeg-save-options" parasite, and the user also has the option to
change and save the defaults (which go into a global parasite
"jpeg-save-defaults")?

-Raphaël
_______________________________________________
Gimp-developer mailing list
Gimp-developer@lists.XCF.Berkeley.EDU
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer

Reply via email to