homm
58484db509
close files after loading for some file types
2017-03-12 20:05:20 +00:00
homm
88ec0bb52f
close file in case of failures
2017-03-12 20:05:20 +00:00
wiredfool
c9f54c98a5
Merge pull request #1938 from wiredfool/python-decoder
...
Pure Python Decoders - fix for MSP decoding
2017-03-12 17:20:19 +00:00
wiredfool
b668db33cd
Updated versionadded to reflect 6-9 month slip [ci skip]
2017-03-11 13:50:19 +00:00
wiredfool
25bc5c76ab
Pure python decoder registry
2017-03-11 13:50:19 +00:00
wiredfool
1e9afb3ecb
Refactor out the palette remapping to Image.Image
2017-03-08 19:41:18 +11:00
Hugo
cb34b686a5
Merge pull request #1822 from radarhere/unused
...
Remove unused imports
2017-02-26 10:05:19 +02:00
Andrew Murray
f9a99652e4
Replaced KeyError catch with dictionary get method
2017-02-25 13:49:05 +11:00
hugovk
0764b2b5e9
Update error message
2017-02-22 08:20:45 +02:00
wiredfool
f0cebebf32
Clarify that draft is only implemented for JPEG and PCD
2017-02-17 06:22:40 -08:00
ces42
8fb44a2bee
More explicit error message when saving to a file with invalid extension ( #2399 )
...
* more explicit error message when saving to a file with invalid extension + test
2017-02-17 13:39:16 +00:00
hugovk
07af06bf8c
Expose and test radial_gradient
2017-01-29 18:44:24 +02:00
hugovk
3ead178d18
flake8
2017-01-29 18:38:06 +02:00
hugovk
47b1c66961
Expose and test linear_gradient
2017-01-29 18:17:31 +02:00
Andrew Murray
c168f01111
Removed imports used only by comments
2017-01-18 20:06:47 +11:00
Andrew Murray
58b5c9187d
Replaced absolute PIL imports with relative imports ( #2349 )
2017-01-17 13:22:18 +00:00
Luis G
67c1258cfc
Expose registered file extensions
...
This adds a new method in Image (registered_extensions) that exposes the
internal EXTENSION dictionary to consumers of the library
2017-01-07 11:32:16 +11:00
wiredfool
fed4b52171
Disable fastpath when using center or translate
2017-01-01 11:13:25 +00:00
wiredfool
f286d8bb34
Documentation param order to match actual order
2017-01-01 11:10:39 +00:00
Marcus Brinkmann
90077b3975
Add center and translate option to Image.rotate.
2016-12-31 19:01:09 +00:00
wiredfool
69bea50810
Allow 0 size images, Fixes #2259
2016-12-31 13:19:29 +00:00
homm
77210e410d
test for common modes and filters
...
pass box for RGBA → RGBa conversion
2016-12-02 16:33:48 +03:00
homm
295382aadc
vertical and horizontal pass with boxes
2016-12-02 15:40:32 +03:00
homm
3d72e9828f
add param info
2016-12-02 03:11:02 +03:00
homm
6def4bfc73
roi → box
2016-11-30 20:01:28 +03:00
Andrew Murray
4ed31e8ef7
Updated comments to use print as a function
2016-11-26 11:02:44 +11:00
Hugo
fb54b1da2e
Merge pull request #2248 from uploadcare/use-_new
...
Use Image._new() instead of _makeself()
2016-11-24 08:32:13 +02:00
homm
f828416752
add roi argument to Image.resize() method
...
constraints check
2016-11-24 04:40:54 +03:00
homm
d4784bffb2
return copy of the image if size matches
2016-11-24 03:30:36 +03:00
homm
14734b1d97
remove _makeself deprecated method
2016-11-24 03:03:31 +03:00
homm
5773fd8396
_makeself → _new
2016-11-23 14:41:43 +03:00
Andrew Murray
38fd77ca7d
Fixed bug in saving to fp-objects in Python >= 3.4
2016-11-15 20:13:25 +11:00
Andrew Murray
c3fe5d4313
Changed behaviour of default box argument for paste method to match docs
2016-11-15 06:37:40 +11:00
Hugo
48b72eac34
Merge pull request #2184 from jdufresne/isinstance
...
Replace type() equality checks with isinstance
2016-11-01 19:07:06 +02:00
Tim Graham
02b5ce0479
Remove redundant space in PIL.Image ImportError message
2016-10-31 11:09:40 -04:00
Jon Dufresne
e44bb42ae9
Replace type() equality checks with isinstance
2016-10-31 06:41:43 -07:00
Matt R. Wilson
74f751037f
Divide floats to eliminate deprecation warning.
...
When running python 2.7 with the `-3` flag the following warning occurs
> .../PIL/Image.py:48: DeprecationWarning: classic int division
MAX_IMAGE_PIXELS = int(1024 * 1024 * 1024 / 4 / 3)
Simply changing the 4 and 3 to be floats instead eliminates the warning
and, because the result is cast, the resulting `int` stays the same for
python 2 and 3.
2016-10-22 11:58:13 -04:00
homm
c5e111e6b8
allow lists as arguments for Image.new
2016-10-04 03:06:35 +03:00
wiredfool
445451c0b9
Added common check for size tuple errors
2016-10-03 07:27:02 -07:00
wiredfool
d9fc1848a2
Merge pull request #2140 from SemanticsOS/lambdafu/tiff-multipage
...
Add TIFF save_all writer.
2016-10-03 06:31:39 -07:00
Eric Soroos
95b50bf611
Make Image.crop an immediate operation, not lazy. Fixes #1077
2016-09-29 13:28:24 -07:00
Marcus Brinkmann
92c7337df0
Add TIFF save_all writer.
2016-09-29 17:05:33 +02:00
Andrew Murray
b58f76dc4f
Renamed references to OS X to macOS
2016-09-23 21:12:03 +10:00
Patrick Snape
e981c41b47
Allow pathlib.Path in Image.open on Python 2.7
...
Although the pathlib backport for Python 2.7 may be deprecated:
https://pypi.python.org/pypi/pathlib/
It is still used by many projects. Therefore, changing to a
Try/Except pattern for checking for pathlib is not any more
obtrusive that the current >= Python 3.4 check and allows users
to use the backport without issue.
2016-09-15 10:05:36 +01:00
Andrew Murray
72d5218080
Flake8 fixes
2016-09-03 12:17:22 +10:00
wiredfool
5d2667efda
Merge pull request #2022 from uploadcare/rotation-pixel-center
...
Respect pixel centers during transform
2016-08-25 11:40:09 +01:00
Matthew Brett
824a0c232c
BF: fix conversion of bit images to numpy arrays
...
Numpy cannot form arrays from bits. To convert bit images to numpy,
convert bits to bytes.
From suggestion by Alexander Karpinsky, with thanks.
Fixes gh-350.
2016-08-17 18:47:14 -07:00
homm
993e49c0be
Merge branch 'master' into rotation-pixel-center
2016-08-07 13:47:16 +03:00
Alexander Karpinsky
bc2c933552
Merge pull request #2052 from uploadcare/rotate-loading
...
Fix image loading when rotating by 0 deg
2016-08-05 19:35:06 +03:00
homm
3185262e31
fix image loading when rotating by 0 deg
2016-08-05 19:20:02 +03:00
homm
2221a6467c
fix test which relied on old bugs
2016-07-11 01:47:25 +03:00
homm
1ba4e9e5ba
remove end of file banner from all files
2016-07-10 14:11:28 +03:00
homm
66715246c1
remove mitchell filter. Has no advantages over bicubic
2016-07-02 01:54:39 +03:00
homm
0e9beed76d
add constants for filters: BOX, HAMMING, MITCHELL
...
rearrange filters everywhere
2016-07-02 01:54:39 +03:00
Bryant Mairs
7d5856bdf7
Corrects fromarray() datatype mapping for integer datatypes.
...
Currently failing for int16LE as of this commit.
2016-06-25 12:20:37 +01:00
matt
53c9a80d1b
Changed equals method on Image so it short circuits. Also put getpalette() and tobytes() comparison at the end because they are the slowest operations.
2016-06-19 17:44:24 -04:00
Andrew Murray
86828ffd2a
Replaced del with pop
2016-06-18 11:25:39 +10:00
homm
78242e4acd
remove stale comment
2016-06-08 16:47:26 +03:00
homm
3d622d60cf
make perspecive transform arguments order more common
2016-06-08 16:17:41 +03:00
homm
2b77b1cec7
make affine transform arguments order more common
2016-06-08 16:17:41 +03:00
homm
6be3df2a43
remove internal ImagingTransform from headers
...
rename to ImagingGenericTransform
2016-06-08 16:17:41 +03:00
homm
1f8c2527ba
internal rotating functions not used anymore
2016-06-08 16:17:41 +03:00
homm
709078efd1
use one self.transform for rotation
2016-06-08 16:17:41 +03:00
homm
7687ce829e
round results of sin and cos functions because there is no possible
...
float-point value of radians which cos will exactly 0.
2016-06-08 16:17:41 +03:00
homm
8203a43d26
Fast paths for rotation
2016-06-08 16:17:41 +03:00
homm
f680b5417b
one code style for all methods
2016-06-08 16:17:41 +03:00
wiredfool
3657bc10a6
Merge pull request #1889 from rr-/libpngquant
...
Add libimagequant support in quantize()
2016-05-26 21:12:25 +01:00
homm
c4b92d09b7
support for La mode
2016-05-26 15:15:08 +03:00
Andrew Murray
da83f9f1d0
Removed support for list form of Image info
2016-05-07 18:33:02 +10:00
rr-
eb354be7c4
Add method=Image.LIBIMAGEQUANT for quantize()
2016-05-05 21:39:16 +02:00
wiredfool
8b9b996327
Merge pull request #1862 from daniel-leicht/fix-generic-use-of-exception
...
Deprecated function will no longer raise "Exception" but "NotImplementedError".
2016-05-05 16:32:05 +01:00
Andrew Murray
41b4f1fd81
Corrected Image show documentation
2016-05-05 19:30:07 +10:00
Pierrick Koch
272588feca
[PIL] Image add support _MODE_CONV LA mode
2016-04-29 21:03:24 +01:00
Pierrick Koch
001bee40ab
[PIL] Image add support fromarray LA mode
...
fix:
>>> img = np.zeros((40,40,2), 'uint8')
>>> Image.fromarray(img)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python2.7/dist-packages/PIL/Image.py", line 1929, in fromarray
raise TypeError("Cannot handle this data type")
TypeError: Cannot handle this data type
2016-04-27 15:23:44 +02:00
daniel
1f4e2a180b
Changed the use of the generic "Exception" to "NotImplementedError" in the deprecated functions.
2016-04-27 11:12:57 +03:00
Andrew Murray
bb0d312de7
Added __copy__ method to Image
2016-03-16 20:23:51 +11:00
wiredfool
fb853267f9
Merge pull request #1748 from radarhere/path
...
Fixed bug when saving to a non-existent path using pathlib
2016-03-14 09:48:53 -07:00
wiredfool
c3bf1e1c78
Merge pull request #1745 from hugovk/crop_integers
...
Round crop's arguments to nearest integers
2016-03-14 09:44:29 -07:00
wiredfool
b1f6cecd70
Merge pull request #1663 from wiredfool/uninitialized-variable
...
Fixes uninitialized variable warning in _imaging.c:getink
2016-03-14 09:41:12 -07:00
wiredfool
10f2faf3ed
Provide a more general error check to catch #1753
2016-03-08 01:04:11 -08:00
Andrew Murray
b959a25f09
Fixed bug when saving to a non-existent path using pathlib
2016-02-27 13:10:50 +11:00
hugovk
239f09435a
Round crop args to nearest integers ( #1744 )
2016-02-24 15:11:08 +02:00
wiredfool
27d8edbed5
Merge pull request #1728 from radarhere/buffer
...
Updated documentation s/fromstring/frombytes
2016-02-23 14:29:57 -08:00
Andrew Murray
46bd536c0c
Corrected documentation reference [ci skip]
2016-02-19 20:11:00 +11:00
Andrew Murray
7bfb2745cb
Updated documentation [ci skip]
2016-02-14 21:02:38 +11:00
Andrew Murray
3a55a20712
Improved alpha_composite documentation
2016-02-01 21:02:43 +11:00
Andrew Murray
a5b2c4da29
Corrected comment
2016-01-31 11:57:02 +11:00
wiredfool
a098c88509
Convert was passing in a 3tuple to putpixel for a P image
2016-01-14 08:58:13 -08:00
wiredfool
436daee5e0
Merge pull request #1591 from radarhere/health
...
Health fixes
2015-12-14 21:00:09 +00:00
wiredfool
65ff8f9f5a
Merge pull request #1578 from cartisan/numpy-conversion-for-hsv
...
Enabled conversion to numpy array for HSV images. #1559
2015-12-14 20:55:47 +00:00
Andrew Murray
c27110ab56
Flake8 fixes
2015-12-10 21:34:02 +11:00
Andrew Murray
5f904ace9d
Removed warnings check
2015-12-09 16:55:33 +11:00
cartisan
8b76f557ce
Enabled conversion to numpy array for HSV images. #1559
2015-12-07 17:40:42 +00:00
Andrew Murray
82c7ea8489
Changed string format argument to logger parameter
2015-12-02 16:32:44 +11:00
mattip
0ff05afa56
test, fix missing 'version' key value in __array_interface__
2015-11-02 20:07:12 +02:00
wiredfool
b7501aa3c0
Merge pull request #1490 from wiredfool/pr1470
...
Reqorded Pr #1470
2015-10-12 07:28:40 -07:00
wiredfool
d8a6a8cc18
Reworded warning
2015-10-12 07:26:58 -07:00
Andrew Murray
6bd7e7f02d
Removed trailing whitespace
2015-10-11 21:24:35 +11:00
masklinn
fc52f73366
Add warning to tobytes
...
It probably isn't what most developers want.
2015-10-05 12:27:25 +02:00
wiredfool
42633d7a31
spaces.
2015-10-03 08:29:52 +01:00