mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-02-05 06:00:58 +03:00
fix docstring tab
This commit is contained in:
parent
24388addb6
commit
8676044a27
|
@ -325,21 +325,21 @@ def getdraw(im=None, hints=None):
|
||||||
|
|
||||||
def floodfill(image, xy, value, border=None, thresh=0):
|
def floodfill(image, xy, value, border=None, thresh=0):
|
||||||
"""
|
"""
|
||||||
(experimental) Fills a bounded region with a given color.
|
(experimental) Fills a bounded region with a given color.
|
||||||
|
|
||||||
:param image: Target image.
|
:param image: Target image.
|
||||||
:param xy: Seed position (a 2-item coordinate tuple). See
|
:param xy: Seed position (a 2-item coordinate tuple). See
|
||||||
:ref:`coordinate-system`.
|
:ref:`coordinate-system`.
|
||||||
:param value: Fill color.
|
:param value: Fill color.
|
||||||
:param border: Optional border value. If given, the region consists of
|
:param border: Optional border value. If given, the region consists of
|
||||||
pixels with a color different from the border color. If not given,
|
pixels with a color different from the border color. If not given,
|
||||||
the region consists of pixels having the same color as the seed
|
the region consists of pixels having the same color as the seed
|
||||||
pixel.
|
pixel.
|
||||||
:param thresh: Optional threshold value which specifies a maximum
|
:param thresh: Optional threshold value which specifies a maximum
|
||||||
tolerable difference of a pixel value from the 'background' in
|
tolerable difference of a pixel value from the 'background' in
|
||||||
order for it to be replaced. Useful for filling regions of non-
|
order for it to be replaced. Useful for filling regions of non-
|
||||||
homogeneous, but similar, colors.
|
homogeneous, but similar, colors.
|
||||||
"""
|
"""
|
||||||
# based on an implementation by Eric S. Raymond
|
# based on an implementation by Eric S. Raymond
|
||||||
# amended by yo1995 @20180806
|
# amended by yo1995 @20180806
|
||||||
pixel = image.load()
|
pixel = image.load()
|
||||||
|
|
Loading…
Reference in New Issue
Block a user