Commit Graph

511 Commits

Author SHA1 Message Date
wiredfool
c546c5a4c0 Added conversion for RGB+Transparency to RGBA that adds an alpha mask corresponding to the transparency value, fixes #421 2013-11-26 12:24:19 -08:00
wiredfool
94e3c75179 Merge from 12-bit-tiff 2013-11-21 21:41:54 -08:00
wiredfool
44e4d6b49d Comments 2013-11-21 20:57:48 -08:00
wiredfool
16c95fc295 Flags to force libtiff read/write 2013-11-21 20:37:52 -08:00
wiredfool
65e3bfaf33 added generic libtiff en/decoder instead of each compression version 2013-11-21 20:37:52 -08:00
wiredfool
9d06fa74be 12 bit tiffs come out as 12 bits from libtiff 2013-11-21 20:37:30 -08:00
wiredfool
886b075526 Merge from master 2013-11-20 22:52:47 -08:00
wiredfool
dbecc1cb70 Fix for failing ImageQt with mode 'L' image 2013-11-20 22:20:13 -08:00
Aurélien Ballier
938323bd2b Add Qt5 support. 2013-11-20 21:34:33 -08:00
wiredfool
e4fe6ae7a3 Read only implementation of 12bit tiffs 2013-11-20 16:56:23 -08:00
Esteban Santana Santana
8d27167fc7 More python3 fixes.
Changed the way the translate command that is passed to ghostscript is generated. This should now work on both python2.6+ and python3.
2013-11-20 02:54:31 -06:00
Esteban Santana Santana
3d1cd63afd We need to write bytes not strings.
Python3 compatibility issue, we need to write bytes to buffers and pipes, not strings. This should still work in python2.6+.
2013-11-20 02:41:35 -06:00
Esteban Santana Santana
9cd654917d Changed the Ghostscript() function inside of EpsImagePlugin to use subprocess.Popen() instead of the deprecated os.popen(). 2013-11-20 01:32:06 -06:00
Esteban Santana Santana
7989378bfd Added a way to specify the render size for EPS files.
There is now a scale parameter that you can pass in to the EpsImageFile.load() function. This parameter is used to specify at what scale Ghostscript renders the EPS internally. Scale needs to be an integer, and all of the internal structures (image size and bounding box) are scaled based on that parameter.
2013-11-17 01:26:44 -06:00
wiredfool
18ced74c06 Image.convert mode 1 documentation update. Fixes #407 2013-11-12 22:42:06 -08:00
David Schmidt
06301c9eba don't create a new palette on Image._new if one already exists (i.e. after im.copy()) 2013-11-12 14:41:35 +01:00
wiredfool
49191c78fb CHECK: support for int arrays as ifd entries 2013-11-07 16:23:20 -08:00
wiredfool
d2f1fa0e5f two additional tags for saving color images with libtiff 2013-11-05 20:49:09 -08:00
Thayne McCombs
840c7b9acb Closes #397. Fixed Viewer.show to return properly.
Viewer.show did not return a value, however ImageShow.show expected
Viewer.show to return a non-falsey value if successful. Therefor ImageShow.show
would continue to call multiple viewers.
2013-10-30 19:40:21 -06:00
Thayne McCombs
4da7c475ec Quote filenames and title before using on command line
This commit quotes title and filename paramaters that are passed to the
command line when showing an image.
2013-10-30 19:29:15 -06:00
cgohlke
42b8ec37d7 Support RGBA TIFF with missing ExtraSamples tag 2013-10-26 18:02:17 -07:00
Alex Clark ☺
e3d85700b4 Merge pull request #390 from wiredfool/webp-lossless
Lossless WEBP Support
2013-10-24 03:08:24 -07:00
Alex Clark ☺
b57d68e993 Merge pull request #389 from wiredfool/libtiff-save
Take compression as an option in the save call for tiffs
2013-10-24 03:03:27 -07:00
Alex Clark ☺
06ba0ea757 Merge pull request #386 from liftoff/master
Add support for saving lossless WebP.  Just pass 'lossless=True' to save()
2013-10-24 03:00:51 -07:00
wiredfool
63995459bc merge from master 2013-10-22 16:18:06 -07:00
wiredfool
f8abb98ffd Merge from master 2013-10-22 16:05:18 -07:00
wiredfool
2c1e800836 added new VP8 mode for lossless reading of RGBA, fixes failing tests 2013-10-22 12:44:09 -07:00
wiredfool
6a0516d2c9 final pass through atts: handling single rational tuple, using isStringType, flattening from single element tuple to string or int 2013-10-22 10:10:37 -07:00
wiredfool
8655209b4a rm debugging print 2013-10-22 09:24:51 -07:00
wiredfool
32e2f97b21 Tag issues with libtiff -- Need to parse the tuples for the ifd and the im.ifd. getattr + default for the im.ifd instead of silent try/except 2013-10-22 09:18:41 -07:00
Eric Soroos
3128a76495 MM and II 16 bit integer tiffs pack/write properly using libtiff on bigendian platform 2013-10-21 22:37:20 +00:00
Eric Soroos
6f8d968cbb MM and II 16 bit integer tiffs unpack properly using libtiff on bigendian platform 2013-10-21 22:17:33 +00:00
wiredfool
7ece94edc7 compression in encoder info 2013-10-21 09:30:06 -07:00
Dan McDougall
0a91541df8 Add support for saving lossless WebP. Just pass 'lossless=True' to save(). 2013-10-20 15:44:22 -04:00
Eric Soroos
175c572432 I;16 images are little endian, not native endian 2013-10-19 03:28:31 +00:00
hugovk
92507e5d0a Fix issue #382: TypeError with TransposedFont's getsize()
When getting the size of text with a TransposedFont it was failing:

  File "/usr/local/lib/python2.7/site-packages/PIL/ImageDraw.py", line 281, in textsize
    return font.getsize(text)
  File "/usr/local/lib/python2.7/site-packages/PIL/ImageFont.py", line 189, in getsize
    w, h = self.font.getsize(text)[0]
TypeError: 'int' object is not iterable

This is because self.font.getsize(text) returns a (w, h) tuple. To fix, remove the [0].

Test cases have been created in test_imagefont.py: 
test_rotated_transposed_font()
test_unrotated_transposed_font()

Both fail before the fix, both pass with the fix. Furthermore, the code I'm using this from ( https://github.com/mattdeboard/word_cloud ) now works as expected and creates a word cloud similar to the ones that PIL created.
2013-10-17 19:00:42 +03:00
Alex Clark ☺
55a0792815 Merge pull request #380 from wiredfool/lcms2
LCMS1 replaced with LCMS2
2013-10-16 09:09:15 -07:00
Stephen Johnson
c3de637362 Fully document PIL.PSDraw 2013-10-13 22:30:00 -07:00
Stephen Johnson
7030e50b36 Fully document PIL.ImageWin 2013-10-13 22:19:12 -07:00
Stephen Johnson
4b4f090258 Fully document PIL.ImageTk 2013-10-13 22:09:02 -07:00
Stephen Johnson
81ea5c35cb Fully document PIL.ImageStat 2013-10-13 21:57:07 -07:00
Stephen Johnson
f284c194ca Fully document PIL.ImageSequence 2013-10-13 21:49:35 -07:00
Stephen Johnson
6566a73bcf Fully document PIL.ImagePath 2013-10-13 21:41:21 -07:00
Stephen Johnson
7881c86bba Document PIL.ImagePalette as best I can 2013-10-13 21:27:07 -07:00
Stephen Johnson
0f3f6dd1a3 Move ImageGrab docs back to ImageGrab.rst instead of autodoc 2013-10-13 09:56:58 -07:00
Stephen Johnson
20b9d9774a Fully document PIL.ImageOps; fix some :py:mod: markup 2013-10-12 22:17:45 -07:00
Stephen Johnson
e2d88b5a51 Fully document ImageMath 2013-10-12 17:40:14 -07:00
Stephen Johnson
cf7b72f9b9 Fully document PIL.ImageGrab 2013-10-12 17:22:02 -07:00
Stephen Johnson
bc0f53aceb Fully document PIL.ImageFont 2013-10-12 17:14:12 -07:00
Stephen Johnson
a2c67dc3af Fully document PIL.ImageFilter 2013-10-12 16:49:32 -07:00
Stephen Johnson
348daf9490 Document ImageFile.Parser 2013-10-12 13:57:27 -07:00
Stephen Johnson
f2be739fdf Fully document PIL.ImageEnhance 2013-10-12 13:48:34 -07:00
wiredfool
ace78d0734 Lab is Uint, Int, Int. Tests failing 2013-10-11 23:31:47 -07:00
Stephen Johnson
88c700f3b2 Fully document PIL.ImageColor 2013-10-11 22:54:24 -07:00
Stephen Johnson
1e726ea36a Remove old ImageChops comments; redundant with docstrings 2013-10-11 22:46:57 -07:00
Stephen Johnson
546c20491f Improve ImageChops docstrings 2013-10-11 22:45:23 -07:00
Stephen Johnson
b533aa665e Fix many formatting mistakes in PIL.Image's docstrings 2013-10-11 22:18:40 -07:00
wiredfool
1c3932e89f Added LAB mode, core dumped 2013-10-10 23:27:34 -07:00
wiredfool
b506e2ad44 Fixed ability to create LAB profiles with color temperatures 2013-10-10 22:42:27 -07:00
wiredfool
ce041fd199 moving string functions into python, py27 and py32 now really work the same 2013-10-10 22:12:45 -07:00
wiredfool
21697f676b Merge branch 'master' into tifftags 2013-10-08 21:34:02 -07:00
wiredfool
08347569b5 Another python 2.6 detail 2013-10-08 11:32:51 -07:00
wiredfool
e9b0b09b72 Python 2.6 compatibility 2013-10-08 10:43:55 -07:00
wiredfool
a91283061e Python3 fixes 2013-10-07 23:30:55 -07:00
wiredfool
e35ed87be6 Writing multiple rational items 2013-10-07 23:09:41 -07:00
wiredfool
0204733fd6 Proper handling of both IFDs for libtiff usage 2013-10-07 23:03:50 -07:00
wiredfool
2188cf2baf typo 2013-10-07 23:03:13 -07:00
wiredfool
e6c8e5abec better handling of unicode, rational tuples 2013-10-07 23:02:59 -07:00
wiredfool
a3d267b96c Changes in the internal representation of ImageFileDirectory 2013-10-07 17:05:27 -07:00
wiredfool
951a5d4ce8 Using the public interface rather than the raw, undecoded interface 2013-10-07 17:05:27 -07:00
wiredfool
ce0e8b6abf streamlining internal representation of types in ImageFileDirectory 2013-10-07 17:05:27 -07:00
Alex Clark ☺
056690792e Merge pull request #364 from wiredfool/premultiply
Alpha Premultiplication support for transform and resize
2013-10-07 06:38:11 -07:00
wiredfool
10214bc6c4 Premultiply RGBA images prior to transform and resize and undo after 2013-10-04 13:25:32 -07:00
Alex Clark ☺
84b0ba7207 Merge pull request #359 from wiredfool/pypy
Fixes to make Pypy 2.1.0 work on Ubuntu 12.04/64
2013-10-03 05:14:23 -07:00
wiredfool
30e6c6d1ab Merge branch 'master' into tifftags 2013-10-02 22:30:01 -07:00
wiredfool
c4f9fa7a40 Py3 -- can't join a string 2013-10-02 22:23:27 -07:00
wiredfool
dbf47837ce Add arbitrary tags to tiff images using an ImageFileDirectory 2013-10-02 22:06:17 -07:00
wiredfool
95b2434eb2 added accessors for the 4 individual info fields 2013-10-02 16:36:20 -07:00
Alex Clark
3c2496e117 Bump 2013-10-02 13:07:32 -04:00
wiredfool
258434b8ef Fix test failures for Pypy 2.1 around memory mapping 2013-10-02 09:56:29 -07:00
wiredfool
13860addc4 versioning 2013-10-01 23:22:45 -07:00
Alex Clark
5dfc5bf256 Bump 2013-09-30 06:13:14 -04:00
Alex Clark ☺
946af1edd2 Merge pull request #346 from mhogg/master
Bug fix for encoding of b_whitespace - Similar to closed issue #272
2013-09-30 02:38:23 -07:00
Michael Hogg
e70424644a Update PpmImagePlugin.py
Making it work for Python 3.x
2013-09-30 17:44:11 +10:00
Michael Hogg
800729e092 Update PpmImagePlugin.py
Bug fix when locale has not been set
2013-09-30 17:24:22 +10:00
Christoph Gohlke
9bff0b14e0 Add numpy array interface support for 16 and 32 bit integer modes 2013-09-29 19:30:43 -07:00
Michael Hogg
20e7555e59 Update PpmImagePlugin.py
Bug fix for encoding of b_whitespace
2013-09-30 09:54:25 +10:00
Christoph Gohlke
2fc724d346 Call _getexif function instead of class method 2013-09-29 09:20:00 -07:00
Christoph Gohlke
c46b3fe256 Make _getexif a function 2013-09-29 09:17:37 -07:00
wiredfool
bb9672095b initial working version of saving arbitrary tags from the img.tags directory 2013-09-28 21:31:32 -07:00
Alex Clark ☺
97ecde836d Merge pull request #344 from wiredfool/tifftags
Tiff Tags
2013-09-28 09:22:05 -07:00
Alex Clark
caacc1dce6 Fix test 2013-09-28 09:46:00 -04:00
Alex Clark
f7393d8977 Add faux test suite
It would be great if we could start moving PIL's tests in to a proper test suite i.e. inside a Python package
2013-09-28 09:26:28 -04:00
wiredfool
465ebd3af3 added tagnames for ImageJ tiff tags 2013-09-27 10:41:27 -07:00
wiredfool
a40950c3b9 Properly set the mode for files with rawmode of F;32BF 2013-09-27 10:41:03 -07:00
paddywwoof
02855a86c0 hopefully this uses a reasonable y offset 2013-09-20 14:02:40 +01:00
paddywwoof
25b39de5b7 ImageColor defaults to alpha = 255 in only rgb specified for RGBA mode 2013-09-19 15:30:08 +01:00
Alex Clark ☺
e5279a284b Merge pull request #325 from manisandro/bytearray
Fix bytes which should be bytearray
2013-08-29 02:14:49 -07:00
Sandro Mani
1c4734b6bb Make bytePalette read-only buffer 2013-08-28 20:44:27 +02:00
Sandro Mani
4be146cf27 Fix bytes which should be bytearray 2013-08-28 20:18:13 +02:00
Alex Clark ☺
07f338f194 Merge pull request #315 from d-schmidt/master
fix Issue #312 + gif optimize improvement
2013-08-22 02:54:43 -07:00
wiredfool
bb29d00fdf Merge pull request #321 from vytisb/master
Fix for #318: Catch truncated zTXt chunk errors when decoding PNG images.
2013-08-21 15:02:03 -07:00
Eric Buehl
26fb0eadad issue warning instead of debug/print 2013-08-20 16:53:55 +00:00
Vytis Banaitis
dbf40a0124 Catch truncated zTXt errors. 2013-08-20 15:17:17 +03:00
Eric Buehl
7430dc261f be more tolerant of tag read failures
this can occur if the MakerNote has a pointer to outside the EXIF block
2013-08-19 22:51:50 +00:00
David Schmidt
9d43f156a8 replace custom search with dict in gif optimize 2013-08-06 11:36:02 +02:00
David Schmidt
c9df9d0b23 reorganized gif optimize to work with palette parameter 2013-08-05 17:59:35 +02:00
David Schmidt
b9ab3f5bf4 fix Issue #312
improve palette handling while saving gif and png
2013-08-02 16:32:49 +02:00
Joaquín Cuenca Abela
c68044bf7f Fix IOError when saving progressive JPEGs.
when the jpeg encoder sees the flags optimize or progressive (or progression)
it will write the full image in one shot.

The bufsize needs to be big enough to hold the entire image. The current heuristic
is that the entire compressed image will fit in width * height bytes, but this
heuristic is only applied to save operations with the flag "optimize" and not to
save operations with the flag "progressive".

This patch fixes this oversight.

(Btw, it will probably be a good idea to have a loop that retries with a bigger
bufsize in case this guess is not big enough.)
2013-08-02 14:36:46 +02:00
Yoav Weiss
c117dcae34 Add RGBA support to ImageColor 2013-07-30 16:43:40 +02:00
Martijn Pieters
97f1cd55ee Fix for #304: test for str, not "utf-8".
The code wants to produce a `str` object for the given Python version (which is the right thing to do here).
2013-07-25 18:21:08 +01:00
Michał Nowotka
702fc75ee3 Update _util.py
Fixing missing import.
2013-07-25 17:25:18 +01:00
Felipe Reyes
64cc8f994d Added some missing exif tags 2013-07-24 18:46:21 +00:00
wiredfool
e3e0638a5f Fail fast if there's an import error on _imaging 2013-07-23 10:17:15 -07:00
Freek Dijkstra
d24a419299 Warnings if imaging library has wrong UCS support.
Raise exceptions for unknown errors.
2013-07-23 10:44:27 +02:00
lmollea
763be8614d Fixed windows fallback (wasn't using correct file in windows/fonts) 2013-07-22 14:44:40 +02:00
Felipe Reyes
a560022341 Transformed docstrings of ImageFile and ImageFileIO modules 2013-07-19 15:11:26 +00:00
wiredfool
db49dbf9de Ignore fillorder=2 when reading using libtiff 2013-07-10 22:36:55 -07:00
Felipe Reyes
15eac684c4
Moved Image module docs from comments to docstrings 2013-07-09 15:12:28 -04:00
Alex Clark ☺
675b4d433c Merge pull request #280 from freyes/add-docstrings-Image
Moved PIL.Image.Image docs from comments to docstrings
2013-07-09 09:15:15 -07:00
Felipe Reyes
25b6371b75
Moved PIL.Image.Image docs from comments to docstrings 2013-07-09 10:32:14 -04:00
wiredfool
c575dff007 ignore high ascii characters in string.whitespace 2013-07-08 22:16:25 -07:00
Bernardo Heynemann
b4735f7829 Adding support for metadata in webp images.
Pillow now uses the webpmux library to envelop the webp images in RIFF. This allows for easy support of exif and icc_profile metadata.

Also included tests that verify compatibility with jpeg for exif and icc_profile metadata.

If the user does not have webp with webpmux enabled, pillow will fall back to the previous approach, meaning no exif or icc_profile metadata will be read or written to.
2013-07-04 18:04:07 -03:00
Alex Clark ☺
fd98b0cceb Merge pull request #268 from megabuz/master
Add several TIFF decoders and encoders
2013-07-01 09:14:43 -07:00
Alexey Buzanov
a130c45990 add several TIFF decoders and encoders 2013-07-01 18:45:42 +04:00
Chris Bailey
08d0ec1e93 Generalizing pterk's ZeroDivisionError fix for 1px images 2013-07-01 12:36:46 +01:00
Alex Clark ☺
3207bf372a Merge pull request #266 from cgohlke/remove-test_imagegl
Remove useless ImageGL module
2013-07-01 03:32:27 -07:00
Christoph Gohlke
f042fd6af3 remove useless ImageGL module 2013-06-30 20:39:12 -07:00
Alex Clark
bb1b3a532c Cleanup WS, courtesy of @Arfrever
find * -type f "-(" -name "*.bdf" -o -name "*.c" -o -name "*.h" -o -name "*.py" -o -name "*.rst" -o -name "*.txt" "-)" -exec sed -e "s/[[:space:]]*$//" -i {} \;
2013-06-30 18:42:19 -04:00
Alex Clark
f56facb0c1 Clean up 2013-06-30 15:21:37 -04:00
Alex Clark
c6a95bf8f4 Add files 2013-06-30 14:50:38 -04:00
Alex Clark
fd29e707e9 Apply @Arfrever patch, fixes #258 2013-06-30 07:04:42 -04:00
Alex Clark ☺
19ad775140 Merge pull request #243 from kostya0shift/master
Better support for ICO files
2013-06-29 16:02:11 -07:00
Peter van Kampen
ad0a96c3fa add test & comment 2013-06-23 15:22:31 +02:00
Peter van Kampen
c9faa9caa5 Fix for ZeroDivisionError in ImageOps.fit for image.size == (1,1) 2013-06-23 12:33:23 +02:00
kostya0shift
738a1dd777 Better support for ICO images 2013-06-05 21:01:05 +04:00
wiredfool
aad417dcbe Merge pull request #229 from wiredfool/warnings
Fixing and Suppressing warnings revealed in #227
2013-05-24 08:36:57 -07:00
Alex Clark ☺
5c11e27a97 Merge pull request #228 from d-schmidt/master
working gif optimization
2013-05-24 05:59:23 -07:00
David Schmidt
b66d888b0e adjust the transparency index after successful optimize
skip transparency block if transparent color is not used after optimize
2013-05-24 13:12:40 +02:00
David Schmidt
71b30352d9 limit custom palette size 2013-05-24 13:16:16 +03:00
David Schmidt
a9cb1281f4 fix Python 2 compatibility 2013-05-24 11:55:31 +02:00
wiredfool
2322619372 fixed deprecation warnings for tostring on array.array 2013-05-23 10:33:27 -07:00
David Schmidt
12cea19280 a break 2013-05-23 15:45:11 +02:00
David Schmidt
dad5e86226 fix gif test, fix gif optimization for palette length < 3 2013-05-23 15:24:06 +02:00
Alex Clark ☺
a9fd1f4a94 Merge pull request #225 from wiredfool/pr224
Fix Image.fromarray with NumPy arrays: Supersedes PR #224
2013-05-23 05:51:58 -07:00
David Schmidt
5cd1b9f01e minor addition 2013-05-23 14:31:48 +02:00
David Schmidt
a466b3e099 fixes #211
replace the gif optimization with a working version
2013-05-23 14:06:09 +02:00
wiredfool
baba2810ae version updates 2013-05-21 21:46:36 -07:00
wiredfool
b3752ca053 merge from master 2013-05-21 21:29:58 -07:00
wiredfool
587b9a79d8 ducktype the array_interface obj to see if it provides tobytes or tostring 2013-05-21 21:04:22 -07:00
Matt Davis
1082173030 Fix Image.fromarray with NumPy arrays
Image.fromarray attempts to call a method called `tobytes()` on the passed in object, but NumPy arrays don't have a `tobytes()` method, they have a `tostring()` method. (See http://docs.scipy.org/doc/numpy/reference/generated/numpy.ndarray.tostring.html).

I think this was changed accidentally in a Python 3 compatibility update in which this call was confused with the `tobytes` and `frombytes` methods of Image objects.
2013-05-21 18:35:11 -03:00
Alex Clark ☺
1c3ff8857a Merge pull request #220 from wiredfool/weba_transparent
Transparent WebP Support, #204
2013-05-16 12:49:02 -07:00
Alex Clark ☺
aea9570a2c Merge pull request #221 from wiredfool/jpeg_memoryleak
Jpeg Decode memory leak fix.
2013-05-16 12:42:45 -07:00
wiredfool
158cdbe8db Enabling cleanup
Enabling the cleanup call in ImageFile.load
2013-05-16 08:32:24 -06:00
wiredfool
f6381ba00c Added cleanup method to prevent memory leaks from truncated jpeg decodes 2013-05-15 21:16:37 -07:00
wiredfool
89b6820530 checking raw image length, cleanup and DRY 2013-05-15 17:04:17 -07:00
wiredfool
11a0fb5f76 consolidated to WebPEncode_wrapper 2013-05-15 16:56:59 -07:00
wiredfool
37359369ce Code to ensure buffer space for exif write and jpeg_write_scanline calls, tests, corrected buffer length calculation 2013-05-14 22:29:31 -07:00
wiredfool
071b8e6b46 Merge branch 'master' into maxblock 2013-05-14 20:37:21 -07:00
wiredfool
b52c22316f inprogress, sorta working 2013-05-13 20:50:10 -07:00
wiredfool
3273b0c4b9 Merge branch 'master' of https://github.com/euangoddard/Pillow into weba_transparent 2013-05-13 09:54:34 -07:00
wiredfool
310341cec7 merge from master 2013-05-13 09:17:52 -07:00
Euan Goddard
1344610a52 Added support for alpha transparent webp images #204 2013-05-13 17:01:42 +01:00
Angel Nunez Mencias
4e9a8ef7d7 Use the JPEG Plugin save instead of calling the ImageFile directly 2013-05-12 02:34:07 +02:00
Matti Picus
af94b45cbc allow integer image resolution as well as rational 2013-05-07 23:33:21 +03:00
Matti Picus
5ca04bb728 a test that fails for images with integer resolution 2013-05-07 23:23:51 +03:00
wiredfool
39c62f76ab Buffer lifetime needs to be the same as the font lifetime 2013-04-25 21:17:58 -07:00
Nicolas Pieuchot
028e63865e Changing bytes variable name not to squeeze bytes type 2013-04-25 23:03:37 +02:00
Nicolas Pieuchot
4d136d94ce Better unity with Image.py file (on string type testing and warnings) 2013-04-25 22:32:43 +02:00
Nicolas Pieuchot
282562ec19 Adding Python3 basestring compatibility without changing basestring 2013-04-25 22:03:37 +02:00
Nicolas Pieuchot
f1c245c9c5 Deprecation message correction 2013-04-25 21:10:42 +02:00
Nicolas Pieuchot
af72132349 Correction of the unbufferizing 2013-04-25 20:57:13 +02:00
Nicolas Pieuchot
450a068ccb Removing buffer from imagefont 2013-04-25 18:48:43 +02:00
Nicolas Pieuchot
ed9945c71f Allowing to pass font as file-like objects 2013-04-22 11:48:06 +02:00
wiredfool
026f6bb61e namespaced operation works when installed as a zipped egg using 'sudo python[3] setup.py easy_install -l --zip-ok .' 2013-04-15 10:57:37 -07:00
Sandro Mani
194370d89b Fix some docstrings 2013-04-12 21:54:21 +02:00
wiredfool
b0fffd24a4 Merge branch 'master' of https://github.com/python-imaging/Pillow into namespaced 2013-04-09 12:08:13 -07:00
David Schmidt
836e3e05d8 create a palette before converting transparent L-Mode to RGBA
fixes #154
2013-04-09 13:21:38 +02:00
wiredfool
8295e33390 moved _webp into the PIL namespace 2013-04-08 21:53:59 -07:00
wiredfool
088c752e40 basic sanity check that the version of the _imaging.c and Image.py files are the same 2013-04-08 21:43:15 -07:00
wiredfool
7f698a6fc5 PIL imports work in python3/Ubuntu 2013-04-08 20:55:06 -07:00
wiredfool
c774f9ab4c merged pull request #88 to master, resolved conflicts 2013-04-08 20:31:28 -07:00
wiredfool
7200c40ada s/tabs/spaces/ 2013-04-05 15:57:07 -07:00
wiredfool
a4a856b58a large exif segments 2013-04-05 15:36:48 -07:00
wiredfool
7129baa9b2 fix for if isinstance(filter, collections.Callable) crash. Python bug #7624 on <2.6.6 2013-03-27 09:44:54 -07:00
Ronald Oussoren
f50feb592b Explitly import JpegPresets from the PIL package 2013-03-26 13:36:13 +01:00
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