massive update, probably broken
[dotfiles/.git] / .config / coc / extensions / node_modules / coc-pyright / node_modules / pyright / dist / typeshed-fallback / stubs / Pillow / PIL / ImageOps.pyi
1 from typing import Any, Iterable, Protocol
2
3 from .Image import Image, _Resample, _Size
4
5 class _Deformer(Protocol):
6     def getmesh(self, image: Image): ...
7
8 def autocontrast(
9     image: Image, cutoff: int = ..., ignore: int | None = ..., mask: Image | None = ..., preserve_tone: bool = ...
10 ) -> Image: ...
11 def colorize(
12     image: Image,
13     black: int | str,
14     white: int | str,
15     mid: int | str | None = ...,
16     blackpoint: int = ...,
17     whitepoint: int = ...,
18     midpoint: int = ...,
19 ) -> Image: ...
20 def contain(image: Image, size: _Size, method: _Resample = ...) -> Image: ...
21 def pad(
22     image: Image, size: _Size, method: _Resample = ..., color: Any | None = ..., centering: Iterable[float] = ...
23 ) -> Image: ...
24 def crop(image: Image, border: int = ...) -> Image: ...
25 def scale(image: Image, factor: float, resample: _Resample = ...) -> Image: ...
26 def deform(image: Image, deformer: _Deformer, resample: _Resample = ...) -> Image: ...
27 def equalize(image: Image, mask: Any | None = ...) -> Image: ...
28 def expand(image: Image, border: int = ..., fill: int = ...) -> Image: ...
29 def fit(image: Image, size: _Size, method: _Resample = ..., bleed: float = ..., centering: Iterable[float] = ...) -> Image: ...
30 def flip(image: Image) -> Image: ...
31 def grayscale(image: Image) -> Image: ...
32 def invert(image: Image) -> Image: ...
33 def mirror(image: Image) -> Image: ...
34 def posterize(image: Image, bits: int) -> Image: ...
35 def solarize(image: Image, threshold: int = ...) -> Image: ...
36 def exif_transpose(image: Image) -> Image: ...