Commit Graph

16405 Commits

Author SHA1 Message Date
Benjamin Gilbert
4d7372bfd0 Implement streamtype=1 option for tables-only JPEG encoding
We already support streamtype=2 to skip producing JPEG tables, but
streamtype=1, which skips everything but the tables, was never implemented.
The streamtype=1 stub code dates to Git pre-history, so it's not
immediately clear why.  Implement the missing support.

jpeg_write_tables() can't resume after a full output buffer (it fails with
JERR_CANT_SUSPEND), so it might seem that Pillow needs to pre-compute the
necessary buffer size.  However, in the normal case of producing an
interchange stream, the tables are written via the same libjpeg codepath
during the first jpeg_write_scanlines() call, and table writes aren't
resumable there either.  Thus, any buffer large enough for the normal case
will also be large enough for a tables-only file.

The streamtype option isn't documented and this commit doesn't change that.
It does add a test though.

Co-authored-by: Andrew Murray <radarhere@users.noreply.github.com>
2023-10-24 20:30:45 -05:00
Hugo van Kemenade
d05ff5059f
Merge pull request #7481 from radarhere/gray 2023-10-20 08:52:46 +03:00
Andrew Murray
19aeed07bf Merge branch 'main' into gray 2023-10-20 07:47:17 +11:00
Hugo van Kemenade
a10dec01b5
Merge pull request #7480 from radarhere/lint 2023-10-19 19:02:28 +03:00
Andrew Murray
e760b02bfa Combine if and assert statement 2023-10-19 20:34:28 +11:00
Andrew Murray
d682c18ded Use "gray" more consistently 2023-10-19 19:12:01 +11:00
Andrew Murray
8b71f3d3c1 Added messages to errors 2023-10-19 18:42:41 +11:00
Hugo van Kemenade
0a6fcc2d97
Merge pull request #7472 from radarhere/libjpeg-turbo
Updated libjpeg-turbo to 3.0.1
2023-10-19 07:52:08 +03:00
Andrew Murray
d652ea804a Updated libjpeg-turbo to 3.0.1 2023-10-17 07:51:56 +11:00
Andrew Murray
f790878853
Merge pull request #7466 from hugovk/10.1.0-3.12
Add Python 3.12 support to Pillow 10.1.0 release notes
2023-10-16 17:20:43 +11:00
Hugo van Kemenade
5207bde09a
Merge pull request #7470 from radarhere/macos
Updated macOS tested Pillow versions
2023-10-16 08:06:48 +03:00
Hugo van Kemenade
286028d263
Wording
Co-authored-by: Andrew Murray <3112309+radarhere@users.noreply.github.com>
2023-10-16 08:05:26 +03:00
Andrew Murray
36f44db8cd Updated macOS tested Pillow versions 2023-10-16 15:34:02 +11:00
Andrew Murray
4593508838
Merge pull request #7468 from hugovk/main
Skip non-wheel CI runs for tags
2023-10-16 09:12:02 +11:00
Andrew Murray
8f9e3ffa7e
Merge pull request #7469 from nulano/typo
Fix typos in ImageOps.rst and tutorial.rst
2023-10-16 08:08:25 +11:00
Andrew Murray
0853adcd92
Merge pull request #7467 from hugovk/update-release-checklist
Update release checklist: macOS/Linux artifact is called 'wheels'
2023-10-16 08:05:08 +11:00
Andrew Murray
76049de4ad Fixed typos in tutorial 2023-10-15 22:39:35 +02:00
Nulano
1979d43c99 fix typo in ImageOps.rst 2023-10-15 22:07:08 +02:00
Hugo van Kemenade
95b0c0b342 Skip non-wheel CI runs for tags 2023-10-15 20:46:25 +03:00
Hugo van Kemenade
d455539d0d Update release checklist: macOS/Linux artifact is called 'wheels' 2023-10-15 20:08:48 +03:00
Hugo van Kemenade
daf1ce78ed Add Python 3.12 to Pillow 10.1.0 release notes 2023-10-15 18:57:14 +03:00
Hugo van Kemenade
0be67e5544 10.2.0.dev0 version bump 2023-10-15 16:05:50 +03:00
Hugo van Kemenade
da59ad000d 10.1.0 version bump 2023-10-15 11:59:17 +03:00
Hugo van Kemenade
d10f802b22
Merge pull request #7465 from radarhere/mode
Describe how to populate mode and size when writing a plugin
2023-10-15 10:01:18 +02:00
Andrew Murray
f50c713583 Move #7307 from "Backwards Incompatible Changes" to "API Changes" 2023-10-15 16:17:45 +11:00
Andrew Murray
a1ddb4dd27 Describe how to populate mode and size 2023-10-15 16:17:19 +11:00
Andrew Murray
4ace56d214 Update CHANGES.rst [ci skip] 2023-10-14 15:33:29 +11:00
Hugo van Kemenade
7bf1a87254
Merge pull request #7354 from radarhere/load_default
Added TrueType default font to allow for different sizes
2023-10-14 06:30:38 +02:00
Hugo van Kemenade
e154e97575
Merge pull request #7463 from radarhere/libimagequant
Updated libimagequant to 4.2.2
2023-10-14 06:27:42 +02:00
Andrew Murray
c759ef2c08 Updated libimagequant to 4.2.2 2023-10-14 11:56:23 +11:00
Andrew Murray
3a40816c51 Update CHANGES.rst [ci skip] 2023-10-14 11:06:20 +11:00
Andrew Murray
c2d50881ee Added documentation 2023-10-14 11:01:57 +11:00
Andrew Murray
0da7ad7c48 Merge branch 'main' into load_default 2023-10-14 10:33:50 +11:00
Hugo van Kemenade
ebefb5f1e0
Merge pull request #7442 from radarhere/warning 2023-10-14 01:30:59 +02:00
Hugo van Kemenade
8e5570e23b
Merge pull request #7444 from radarhere/bgr 2023-10-14 01:30:31 +02:00
Andrew Murray
31d4c7797e Update CHANGES.rst [ci skip] 2023-10-14 10:00:12 +11:00
mergify[bot]
a4bc7146e5
Merge pull request #7412 from radarhere/cover
Added ImageOps cover method
2023-10-13 22:16:30 +00:00
Hugo van Kemenade
ff37a5be37
Merge pull request #7458 from radarhere/truncated_exif 2023-10-13 23:49:55 +02:00
Hugo van Kemenade
101154e0d5
Merge pull request #7437 from radarhere/apng 2023-10-13 23:48:22 +02:00
Hugo van Kemenade
5666c05bf3
Merge pull request #7460 from radarhere/new 2023-10-13 23:45:12 +02:00
Hugo van Kemenade
810f5f06c4
Merge branch 'main' into cover 2023-10-13 23:42:06 +02:00
Andrew Murray
31df7b1655 Use new() instead of Image()._new() 2023-10-13 15:41:26 +11:00
Andrew Murray
7319d86328 Catch struct.error from truncated EXIF when reading DPI 2023-10-12 10:13:46 +11:00
Andrew Murray
4ecf1df4ea
Merge pull request #7453 from nulano/brotli
Fix libbrotli build for Windows wheels
2023-10-10 07:31:46 +11:00
mergify[bot]
ba09e11a3a
Merge pull request #7452 from radarhere/libtiff
Updated libtiff to 4.6.0
2023-10-09 19:55:42 +00:00
Nulano
a0b1c0ab00 fix brotli build on Windows 2023-10-09 17:43:28 +02:00
Andrew Murray
7cd792cf0c Updated libtiff to 4.6.0 2023-10-09 21:49:51 +11:00
mergify[bot]
28affdbaf9
Merge pull request #7451 from radarhere/brotli
Updated brotli to 1.1.0
2023-10-09 10:42:59 +00:00
Andrew Murray
00722fc3c5 Updated brotli to 1.1.0 2023-10-09 20:14:42 +11:00
Hugo van Kemenade
8e8c08fc03
Merge pull request #7449 from radarhere/travis 2023-10-08 08:15:21 +02:00