I have noticed that PIL reduces the size of a sample image I tested with.
I haven't had a chance to figure out how to package PIL with py2exe tho. They use those nifty import function calls, so a bunch of files are omitted from the distriubtion package.
Curiously enough, wxPython has no problem reading the PIL generated PNG's but it doesn't write 'em like PIL does.
An ideal solution would be to refactor the wxWidgets to use the higher compression algorithms (by default?) But that's a time consuming project. PIL is the easier solution.
Argh, what did I do with all that time I had yesterday?
-Joe
Peter Damoc wrote:
···
On Fri, 15 Apr 2005 16:30:17 +0300, Gabriele Farina *DarkBard* > <darkbard@extending-php.net> wrote:
Robin Dunn wrote:
Gabriele Farina *DarkBard* wrote:
Hi, how can I use wx.Image.SaveFile to export PNG 8 images?
wx.Image has SetOption(name, value) and SetOptionInt(name, intValue) methods that can be used to set format-specific options. For PNGs there are wx.IMAGE_OPTION_PNG_FORMAT and wx.IMAGE_OPTION_PNG_BITDEPTH option names defined.
Ok, I tryed to use
image.SetOptionInt(wx.IMAGE_OPTION_PNG_BITDEPTH, 8)
but the image size doesn't change ... someone knows if there is a way to save PNG images so they take the least disk space without too much detail?try with PIL, maybe the files are smaller.
Peter.
---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org