[Image-SIG] passing options to an image plugin encoder
kpoman at hotmail.com
Thu Dec 30 03:19:47 CET 2010
I developped a WSQ image plugin (for fingerprint images).
It works fine for encode and decode functions.
However there are options one would love to pass. The options are, for example, the target bitrate of the compression, or the image comments (to be put on the image headers).
I dont know how to do that. I tried to add some info keys like bitrate etc... However if I print the .info dict on the _save method, it is always empty !
>>> import Image
>>> l__img = Image.open('fgp_1.wsq')
>>> l__img.info['bitrate'] = 0.1
>>> print l__img.info
And obviously the action is not performed. How can I pass options, arguments, keywords or whatever to the encoder so I can read them on the _save method ?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Image-SIG