
    (ph7                        S SK Jr  SSKJrJrJr   " S S5      r " S S\5      r " S S	\5      r " S
 S\5      r	 " S S\5      r
g)    )annotations   )ImageImageFilter	ImageStatc                  4    \ rS rSr% S\S'   S\S'   SS jrSrg)	_Enhance   Image.Imageimage
degeneratec                Z    [         R                  " U R                  U R                  U5      $ )au  
Returns an enhanced image.

:param factor: A floating point value controlling the enhancement.
               Factor 1.0 always returns a copy of the original image,
               lower factors mean less color (brightness, contrast,
               etc), and higher values more. There are no restrictions
               on this value.
:rtype: :py:class:`~PIL.Image.Image`
)r   blendr   r   )selffactors     C/var/www/html/venv/lib/python3.13/site-packages/PIL/ImageEnhance.pyenhance_Enhance.enhance   s     {{4??DJJ??     N)r   floatreturnr   )__name__
__module____qualname____firstlineno____annotations__r   __static_attributes__r   r   r   r	   r	      s    @r   r	   c                  "    \ rS rSrSrSS jrSrg)Color+   zAdjust image color balance.

This class can be used to adjust the colour balance of an image, in
a manner similar to the controls on a colour TV set. An enhancement
factor of 0.0 gives a black and white image. A factor of 1.0 gives
the original image.
c                    Xl         SU l        SUR                  5       ;   a  SU l        UR                  U R                  5      R                  UR                  5      U l        g )NLALA)r   intermediate_modegetbandsconvertmoder   r   r   s     r   __init__Color.__init__4   sK    
!$%..""%)D"--(>(>?GG

Sr   )r   r   r&   Nr   r   r   Noner   r   r   r   __doc__r+   r   r   r   r   r    r    +   s    Tr   r    c                  "    \ rS rSrSrSS jrSrg)Contrast=   zAdjust image contrast.

This class can be used to control the contrast of an image, similar
to the contrast control on a TV set. An enhancement factor of 0.0
gives a solid gray image. A factor of 1.0 gives the original image.
c                   Xl         [        [        R                  " UR	                  S5      5      R
                  S   S-   5      n[        R                  " SUR                  U5      R	                  UR                  5      U l
        SUR                  5       ;   a+  U R                  R                  UR                  S5      5        g g )Nr#   r   g      ?r$   )r   intr   Statr(   meanr   newsizer)   r   r'   putalpha
getchannel)r   r   r7   s      r   r+   Contrast.__init__E   s    
9>>%--"45::1=CD))CT:BB5::N%..""OO$$U%5%5c%:; #r   r   r   Nr-   r/   r   r   r   r2   r2   =   s    <r   r2   c                  "    \ rS rSrSrSS jrSrg)
BrightnessN   zAdjust image brightness.

This class can be used to control the brightness of an image.  An
enhancement factor of 0.0 gives a black image. A factor of 1.0 gives the
original image.
c                    Xl         [        R                  " UR                  UR                  S5      U l        SUR                  5       ;   a+  U R
                  R                  UR                  S5      5        g g )Nr   r$   )	r   r   r8   r)   r9   r   r'   r:   r;   r*   s     r   r+   Brightness.__init__V   sT    
))EJJ

A>%..""OO$$U%5%5c%:; #r   r=   Nr-   r/   r   r   r   r?   r?   N       <r   r?   c                  "    \ rS rSrSrSS jrSrg)	Sharpness^   zAdjust image sharpness.

This class can be used to adjust the sharpness of an image. An
enhancement factor of 0.0 gives a blurred image, a factor of 1.0 gives the
original image, and a factor of 2.0 gives a sharpened image.
c                    Xl         UR                  [        R                  5      U l        SUR                  5       ;   a+  U R                  R                  UR                  S5      5        g g )Nr$   )r   filterr   SMOOTHr   r'   r:   r;   r*   s     r   r+   Sharpness.__init__f   sN    
,,{'9'9:%..""OO$$U%5%5c%:; #r   r=   Nr-   r/   r   r   r   rE   rE   ^   rC   r   rE   N)
__future__r    r   r   r   r	   r    r2   r?   rE   r   r   r   <module>rM      sN   ( # + +@ @$TH T$<x <"< < < <r   