File: ImageChops.rst

package info (click to toggle)
pillow 12.0.0-1
  • links: PTS
  • area: main
  • in suites: forky, sid
  • size: 72,636 kB
  • sloc: python: 49,518; ansic: 38,787; makefile: 302; sh: 168; javascript: 85
file content (45 lines) | stat: -rw-r--r-- 1,761 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
.. py:module:: PIL.ImageChops
.. py:currentmodule:: PIL.ImageChops

:py:mod:`~PIL.ImageChops` ("channel operations") module
=======================================================

The :py:mod:`~PIL.ImageChops` module contains a number of arithmetical image
operations, called channel operations (“chops”). These can be used for various
purposes, including special effects, image compositions, algorithmic painting,
and more.

For more pre-made operations, see :py:mod:`~PIL.ImageOps`.

At this time, most channel operations are only implemented for 8-bit images
(e.g. “L” and “RGB”).

Functions
---------

Most channel operations take one or two image arguments and returns a new
image. Unless otherwise noted, the result of a channel operation is always
clipped to the range 0 to MAX (which is 255 for all modes supported by the
operations in this module).

.. autofunction:: PIL.ImageChops.add
.. autofunction:: PIL.ImageChops.add_modulo
.. autofunction:: PIL.ImageChops.blend
.. autofunction:: PIL.ImageChops.composite
.. autofunction:: PIL.ImageChops.constant
.. autofunction:: PIL.ImageChops.darker
.. autofunction:: PIL.ImageChops.difference
.. autofunction:: PIL.ImageChops.duplicate
.. autofunction:: PIL.ImageChops.invert
.. autofunction:: PIL.ImageChops.lighter
.. autofunction:: PIL.ImageChops.logical_and
.. autofunction:: PIL.ImageChops.logical_or
.. autofunction:: PIL.ImageChops.logical_xor
.. autofunction:: PIL.ImageChops.multiply
.. autofunction:: PIL.ImageChops.soft_light
.. autofunction:: PIL.ImageChops.hard_light
.. autofunction:: PIL.ImageChops.overlay
.. autofunction:: PIL.ImageChops.offset
.. autofunction:: PIL.ImageChops.screen
.. autofunction:: PIL.ImageChops.subtract
.. autofunction:: PIL.ImageChops.subtract_modulo