mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-07-04 11:53:32 +03:00
Merge pull request #5352 from radarhere/quantize_documentation
This commit is contained in:
commit
9b69d94082
|
@ -486,15 +486,16 @@ Used to specify the quantization method to use for the :meth:`~Image.quantize` m
|
||||||
|
|
||||||
.. data:: MEDIANCUT
|
.. data:: MEDIANCUT
|
||||||
|
|
||||||
Median cut
|
Median cut. Default method, except for RGBA images. This method does not support
|
||||||
|
RGBA images.
|
||||||
|
|
||||||
.. data:: MAXCOVERAGE
|
.. data:: MAXCOVERAGE
|
||||||
|
|
||||||
Maximum coverage
|
Maximum coverage. This method does not support RGBA images.
|
||||||
|
|
||||||
.. data:: FASTOCTREE
|
.. data:: FASTOCTREE
|
||||||
|
|
||||||
Fast octree
|
Fast octree. Default method for RGBA images.
|
||||||
|
|
||||||
.. data:: LIBIMAGEQUANT
|
.. data:: LIBIMAGEQUANT
|
||||||
|
|
||||||
|
|
|
@ -1059,6 +1059,12 @@ class Image:
|
||||||
:data:`LIBIMAGEQUANT` (libimagequant; check support using
|
:data:`LIBIMAGEQUANT` (libimagequant; check support using
|
||||||
:py:func:`PIL.features.check_feature`
|
:py:func:`PIL.features.check_feature`
|
||||||
with ``feature="libimagequant"``).
|
with ``feature="libimagequant"``).
|
||||||
|
|
||||||
|
By default, :data:`MEDIANCUT` will be used.
|
||||||
|
|
||||||
|
The exception to this is RGBA images. :data:`MEDIANCUT` and
|
||||||
|
:data:`MAXCOVERAGE` do not support RGBA images, so
|
||||||
|
:data:`FASTOCTREE` is used by default instead.
|
||||||
:param kmeans: Integer
|
:param kmeans: Integer
|
||||||
:param palette: Quantize to the palette of given
|
:param palette: Quantize to the palette of given
|
||||||
:py:class:`PIL.Image.Image`.
|
:py:class:`PIL.Image.Image`.
|
||||||
|
|
Loading…
Reference in New Issue
Block a user