How to save High Quality JPG image by setting Image module from PIL

D

Daniel Mark

hello all:

I am using Image module from PIL to save created image as JPG format.

Is there any option I could set for function Image.save so that the
stored image will have the highest quality.



Thank you
-Daniel
 
F

Fredrik Lundh

Daniel said:
I am using Image module from PIL to save created image as JPG format.

Is there any option I could set for function Image.save so that the
stored image will have the highest quality.

something like

im.save(filename, quality=90)

should do the trick.

if you want to play with the quality setting, reading the "jpeg quality
100 is overkill" part of this post:

http://article.gmane.org/gmane.comp.python.image/115/match=overkill

might also be a good idea.

</F>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,813
Latest member
lawrwtwinkle111

Latest Threads

Top