wiredfool
2a743c9527
JpegImagePlugin sets bufsize for optimized images
2013-03-22 22:27:12 -07:00
David Schmidt
511adfacf7
fix png decode tRNS pattern
2013-03-21 21:00:25 +01:00
David Schmidt
ecd55629be
fix indention
2013-03-21 18:47:37 +01:00
David Schmidt
1a40613ca5
fix indention
2013-03-21 18:43:22 +01:00
David Schmidt
09315f263b
fixing save of transparency palette png-images
2013-03-21 18:16:00 +01:00
David Schmidt
1ff2b6630a
fixed bug with png-images with transparency palette
2013-03-21 16:54:04 +01:00
wiredfool
754eb19d9d
Fixing deprecation warning on py26
2013-03-19 13:53:37 -07:00
Christoph Gohlke
1f41e25b4f
Fix AttributeError: 'module' object has no attribute 'isNumberType'
2013-03-16 09:16:54 -07:00
wiredfool
1540d46ca9
support for the differences between StringIO and BytesIO
2013-03-14 10:36:15 -07:00
Alex Clark ☺
ae45b38286
Merge pull request #112 from cgohlke/patch-9
...
Support uint32 TIFF
2013-03-14 03:55:14 -07:00
Christoph Gohlke
64c25bcf89
Compare prefix to byte strings
2013-03-13 23:28:30 -07:00
Christoph Gohlke
dbfaff5673
Support uint32 TIFF
2013-03-13 21:08:24 -07:00
Christoph Gohlke
b9b6972097
Use BytesIO instead of StringIO
2013-03-13 19:42:21 -07:00
Christoph Gohlke
a26d7b6261
Decode bytestr instead of str
2013-03-13 19:18:40 -07:00
Christoph Gohlke
0df7744845
Fix imports
2013-03-13 19:03:38 -07:00
Alex Clark ☺
8ee5dc3056
Merge pull request #106 from cgohlke/patch-4
...
Better import of _imagingagg and ImageDraw2
2013-03-13 18:03:30 -07:00
Christoph Gohlke
a442d5fa06
Better import of _imagingagg and ImageDraw2
2013-03-13 18:01:15 -07:00
Alex Clark ☺
6c565e980f
Merge pull request #105 from cgohlke/patch-3
...
Better import of Tkinter
2013-03-13 18:00:38 -07:00
Christoph Gohlke
706812ec87
Better import of Tkinter
2013-03-13 17:58:11 -07:00
Christoph Gohlke
4985d96d03
Better import of _imagingft
2013-03-13 17:56:33 -07:00
Alex Clark ☺
62bb9aaaa2
Merge pull request #98 from wiredfool/g4_support
...
G4 Tiff support
2013-03-13 15:41:33 -07:00
Alex Clark ☺
bb186fe516
Merge pull request #96 from lqs/master
...
add support for webp
2013-03-13 04:39:42 -07:00
wiredfool
7226d0dc26
Merge branch 'master' into g4_support
2013-03-12 22:24:36 -07:00
Oliver Tonnhofer
2d478fe82a
fixed check for str with Python 3
2013-03-12 21:29:46 +01:00
Liu Qishuai
a49ea5d326
add support for webp
2013-03-12 22:30:59 +08:00
wiredfool
a3b4697965
typo
2013-03-11 22:04:34 -07:00
Oliver Tonnhofer
6a450e303d
reduce PNG palette size for images <255 colors
...
limit color and trancparency palette to 2^bits entries, when a PNG is
saved with the 'bits' PNG encoder option
2013-03-11 20:58:54 +01:00
Oliver Tonnhofer
6537ba19c3
backport PIL's PNG/Zip improvements
...
- add new FASTOCTREE quantizer with alpha support
- make ZIP compress level and type configurable
- support reading/writing PNGs with paletted alpha
source 3637439d51
2013-03-11 20:33:04 +01:00
Oliver Tonnhofer
c60bb09fcd
Revert "Added support for PNG images with transparency palette"
...
This reverts commit 5baa1ac1b8
.
2013-03-11 19:02:54 +01:00
Oliver Tonnhofer
1db3f9d53f
Revert "Fix KeyError in Tests/test_file_xpm.py"
...
This reverts commit b29326b175
.
2013-03-11 19:02:44 +01:00
wiredfool
4f2a1f9715
() for print, since we're using print_statement
2013-03-08 21:15:22 -08:00
wiredfool
5ba6564e26
initial merge of wiredfool/Python-Imaging-Library-G4-Tiff-Support
2013-03-08 19:51:59 -08:00
Alex Clark
6999860786
Revert "Use relative import for _imagingagg"
...
This reverts commit 34a5311e1b
.
2013-03-08 18:43:52 -05:00
Alex Clark
de077c9d37
Revert "Use relative import for _imagingtk"
...
This reverts commit 5820716eb3
.
2013-03-08 18:43:00 -05:00
Alex Clark
6e00a9c355
Revert "Use relative import for _imaginggl"
...
This reverts commit 5e203de327
.
2013-03-08 18:42:21 -05:00
Alex Clark
4546d26413
Revert "Better import for _imagingft"
...
This reverts commit 089a04bce1
.
2013-03-08 18:41:19 -05:00
Alex Clark
44d25a238c
Revert "Use relative import for _imagingcms"
...
This reverts commit 1003e4f7ee
.
2013-03-08 18:40:21 -05:00
Alex Clark
cbb93ac5bf
Revert "Use relative import for _imagingmath"
...
This reverts commit c731513318
.
2013-03-08 18:39:17 -05:00
Alex Clark
33f42c7fbd
Revert "Use relative import for _imaging"
...
This reverts commit aff6eccec5
.
2013-03-08 18:38:26 -05:00
Alex Clark
fd81ee9336
Fix imports
2013-03-08 17:39:50 -05:00
Christoph Gohlke
34a5311e1b
Use relative import for _imagingagg
2013-03-08 13:47:41 -08:00
Christoph Gohlke
5820716eb3
Use relative import for _imagingtk
2013-03-08 13:43:43 -08:00
Christoph Gohlke
c731513318
Use relative import for _imagingmath
2013-03-08 13:40:30 -08:00
Christoph Gohlke
5e203de327
Use relative import for _imaginggl
2013-03-08 13:38:37 -08:00
Christoph Gohlke
089a04bce1
Better import for _imagingft
2013-03-08 13:36:32 -08:00
Christoph Gohlke
1003e4f7ee
Use relative import for _imagingcms
2013-03-08 13:34:08 -08:00
Christoph Gohlke
aff6eccec5
Use relative import for _imaging
2013-03-08 13:30:41 -08:00
Christoph Gohlke
caba4e33ba
Fix AttributeError: 'module' object has no attribute 'spawn'
2013-03-08 11:15:28 -08:00
Alex Clark
b03abf2e58
Merge branch 'master' of https://github.com/etienned/Pillow into etienned-master
2013-03-08 08:36:53 -05:00
Alex Clark
0c18a8f3b8
Use bytes literal, fixes Tests/test_file_fli.py
2013-03-08 08:01:56 -05:00
Alex Clark
b29326b175
Fix KeyError in Tests/test_file_xpm.py
2013-03-07 15:20:52 -05:00
Alex Clark
3020c16eaa
Fix imports
2013-03-07 11:20:28 -05:00
Alex Clark
f29950bc6d
Fix typo
2013-03-07 08:52:44 -05:00
Alex Clark ☺
cd1cc66d4d
Merge pull request #73 from pelson/tiff_tags
...
Added the ``named`` method to a Tiffs tag getter.
2013-03-07 05:51:39 -08:00
Phil Elson
603f2a226f
Added the `named
` method to a Tiffs tag getter.
2013-03-07 12:00:19 +00:00
Mikhail Korobov
c59c6609f3
Restore fromstring & tostring aliases in 3.x
2013-03-07 15:23:40 +06:00
etienne
55f2dc7b0b
Added quantization tables and subsampling options to the JPEG encoder.
2013-03-06 20:23:02 -05:00
Kyle MacFarlane
de17144f6b
Fix Ghostscript command on Windows
2013-03-06 17:36:22 +00:00
Alex Clark ☺
001a1521cb
Merge pull request #64 from kmike/master
...
Testing improvements and better Python 3.x support
2013-03-05 12:11:07 -08:00
Alex Clark ☺
d58006af39
Merge pull request #57 from garnertb/exif_tags
...
Updated tags to the 2.3 standard and fixed spelling error in the comment...
2013-03-05 12:03:24 -08:00
Alex Clark ☺
d097fa068c
Merge pull request #56 from cgohlke/patch-4
...
BUG: PIL Image array interface has the wrong size for YCbCr
2013-03-05 12:02:05 -08:00
Alex Clark ☺
9ed98814ce
Merge pull request #53 from cgohlke/patch-1
...
BUG: Windows image viewer unable to open image
2013-03-05 10:47:45 -08:00
Mikhail Korobov
a71183dab5
better fix for #15 (with a test case now)
2013-02-26 17:12:11 +06:00
Mikhail Korobov
ee794e1501
An attempt to fix #15 for Python 3.x.
...
TiffImagePlugin.ImageFileDirectory.__getattr__ is magical because it deletes items from "tagdata" variable and this plays badly with TiffImagePlugin.ImageFileDirectory.__iter__. Under Python 2.x items() returned a list and this wasn't a problem (because __iter__ value was evalued once); under Python 3.x items() returns a view/iterator that chains self.tags and self.tagdata and iteration begins to fail with "RuntimeError: dictionary changed size during iteration" exception because tagdata item is modified.
In this changeset I've tried to fix this by evaluating items() when the loop starts (by casting it to list), so that it doesn't matter if tagdata is changed during iteration or not.
There is no tests because _getexif is currently private. But this method is used by easy-thumbnails and sorl.thumbnails, so I think it is worth fixing it.
2013-02-26 16:44:47 +06:00
Mikhail Korobov
bb4eb53859
fix UnboundLocalError errors
2013-02-26 16:31:44 +06:00
Mikhail Korobov
aacb8097c3
better warning messages for fromstring/tostring
2013-02-26 16:19:35 +06:00
Tyler Garner
fa2b10d5da
Updated tags to the 2.3 standard and fixed spelling error in the comments.
2013-02-16 11:16:16 -05:00
Christoph Gohlke
bb07471d2e
BUG: PIL Image array interface has the wrong size for YCbCr
2013-02-13 19:52:32 -08:00
Christoph Gohlke
dbf3d993ed
BUG: Windows image viewer unable to open image
...
The issue was reported several times during the past years.
The temporary bitmap file is deleted before the image viewer is started. The workaround is to wait some time before deleting the file.
http://stackoverflow.com/questions/4607633/image-format-to-save-in-python
http://stackoverflow.com/questions/7715501/pil-image-show-doesnt-work-on-windows-7
2013-02-13 18:23:30 -08:00
Alex Clark
cb4f0f2b3c
Revert "Fix saving images with added transparency"
...
This reverts commit cc439099c1
.
2013-02-06 09:25:03 -05:00
Sandro Mani
cc439099c1
Fix saving images with added transparency
...
See http://mail.python.org/pipermail/image-sig/1999-February/000648.html
This patch was carried by fedora for python-imaging
2013-02-06 00:49:26 +01:00
David Schmidt
5baa1ac1b8
Added support for PNG images with transparency palette
2013-02-01 17:52:22 +01:00
David Schmidt
e90d90d60a
Fixed another PIL Pillow difference bug
2013-01-11 14:41:38 +01:00
David Schmidt
33bf5d9d37
Improved load truncated images
2013-01-11 14:40:02 +01:00
David Schmidt
ee04c7ceea
Fixed another difference between PIL and Pillow
2013-01-11 13:24:44 +01:00
d-schmidt
addf0f4d95
Added possibility to save exif information in jpeg-files
2013-01-10 21:36:21 +01:00
d-schmidt
54d4f5eb3c
added option to load truncated image-files
2013-01-10 20:44:41 +01:00
d-schmidt
900f3a8ff7
Added possibility to save gifs with a custom palette when using color mode P
2013-01-10 20:34:58 +01:00
Brian J. Crowell
c952134e00
py3k: Issue warnings when using the old fromstring/tostring
...
...although, you have to turn on deprecation warnings specifically in order
to get them.
2013-01-10 08:47:05 -06:00
Brian Crowell
848579af9b
py3k: Add Windows icon sanity test
2013-01-10 08:47:04 -06:00
Brian Crowell
276cc421f7
py3k: Add XPM read test
...
This test includes an XPM file with transparency.
2013-01-10 08:47:03 -06:00
Brian Crowell
d6a0dec15b
py3k: Add TarIO test
...
Not too convinced of the size fix. While it works against my file, I'm not
sure someone would have accidentally been an index off and not noticed.
2013-01-10 08:47:03 -06:00
Brian Crowell
49b0d1563e
py3k: Rewrite PdfImagePlugin into something more legible
...
After adding all the encode() calls, the PDF plugin (and a few others)
became much harder to read. This should be much easier on the eyes.
2013-01-10 08:47:02 -06:00
Brian Crowell
6765b8e026
py3k: Add .FLI sanity check, and fix palette bytes bug
2013-01-10 08:47:01 -06:00
Brian Crowell
4f7d784a71
py3k: Actually fix the EPS encoder
...
The EPS encoder wasn't part of Gohlke's test suite, so the previous "fixes"
there were only expected syntactic ones. This gives a cleaner fix to the
encoder.
The decoder doesn't work in round-trip due to a missing eps_decoder method
on the core module, but it's clear it worked at some point.
2013-01-10 08:47:00 -06:00
Brian Crowell
63be4a1334
py3k: Get rid of _ParserFile; io.BytesIO does its job
2013-01-10 08:46:59 -06:00
Brian Crowell
8035b1a76a
py3k: FIX: TGA missing o8 declaration
...
Plus, TGA was eligible for a round-trip test in test_imagefile. It has one
now.
2013-01-10 08:46:59 -06:00
Brian Crowell
254f0cf674
py3k: FIX: Bad upside-down check in BmpImagePlugin
2013-01-10 08:46:58 -06:00
Brian Crowell
a7e3b2e47b
py3k: The big push
...
There are two main issues fixed with this commit:
* bytes vs. str: All file, image, and palette data are now handled as
bytes. A new _binary module consolidates the hacks needed to do this
across Python versions. tostring/fromstring methods have been renamed to
tobytes/frombytes, but the Python 2.6/2.7 versions alias them to the old
names for compatibility. Users should move to tobytes/frombytes.
One other potentially-breaking change is that text data in image files
(such as tags, comments) are now explicitly handled with a specific
character encoding in mind. This works well with the Unicode str in
Python 3, but may trip up old code expecting a straight byte-for-byte
translation to a Python string. This also required a change to Gohlke's
tags tests (in Tests/test_file_png.py) to expect Unicode strings from
the code.
* True div vs. floor div: Many division operations used the "/" operator
to do floor division, which is now the "//" operator in Python 3. These
were fixed.
As of this commit, on the first pass, I have one failing test (improper
handling of a slice object in a C module, test_imagepath.py) in Python 3,
and three that that I haven't tried running yet (test_imagegl,
test_imagegrab, and test_imageqt). I also haven't tested anything on
Windows. All but the three skipped tests run flawlessly against Pythons
2.6 and 2.7.
2013-01-10 08:46:56 -06:00
Brian Crowell
275a895952
py3k: Type coercion is gone
...
Types aren't automatically converted for operations for you.
2013-01-10 08:46:55 -06:00
Brian Crowell
80c2fa60ae
py3k: Sort by key, not cmp
...
Py3k only supports key because it's more efficient. Not even sure 2to3
checks for this.
2013-01-10 08:46:54 -06:00
Brian Crowell
af94e2d93d
py3k: Map long type to int
...
int() is really now long() in py3k, but to avoid breaking 2.6/2.7, we leave
the integer types where they are and just map long to int in py3k.
Also, pretty proud of myself for finding an easy way of detecting py3k.
2013-01-10 08:46:54 -06:00
Brian Crowell
31c454b925
py3k: 2to3's "idiom" filter
...
This is, I guess, a few things the Python devs were just fed up with.
* "while 1" is now "while True"
* Types are compared with isinstance instead of ==
* Sort a list in one go with sorted()
My own twist is to also replace type('') with str, type(()) with tuple,
type([]) with list, type(1) with int, and type(5000.0) with float.
2013-01-10 08:46:53 -06:00
Brian Crowell
48cf699fe6
py3k: Change apply() to unpacking syntax
...
apply() is no longer available in py3k.
2013-01-10 08:46:52 -06:00
Brian Crowell
e2283c664b
py3k: Integer long literals are no longer valid syntax
2013-01-10 08:46:52 -06:00
Brian Crowell
260c1fad14
py3k: Convert StringIO.StringIO to io.BytesIO
...
io.BytesIO is already in 2.6. Some of the more obvious bytes literals are
marked in this commit.
2013-01-10 08:46:51 -06:00
Brian Crowell
dda0e9a3ed
py3k: Tkinter module is now tkinter
2013-01-10 08:46:51 -06:00
Brian Crowell
fa348ee9fe
py3k: __builtin__ module is now builtins
2013-01-10 08:46:50 -06:00
Brian Crowell
dfb1b144d8
py3k: Remove Image types import
...
For awhile now, str == type("") and so on. So we use the appropriate int,
str, basestring, or tuple type where applicable.
2013-01-10 08:46:49 -06:00
Brian Crowell
83ff0b3b31
py3k: Use relative imports
...
In py3k, imports are absolute unless using the "from . import" syntax.
This commit also solves a recursive import between Image, ImageColor, and
ImagePalette by delay-importing ImagePalette in Image.
I'm not too keen on this commit because the syntax is ugly. I might go back
and prefer the prettier "from PIL import".
2013-01-10 08:46:48 -06:00