Warning: session_start(): Session cannot be started after headers have already been sent in /home/tvrreohg/public_html/manga.php on line 13
3 ia�ã@s¾ddlmZdd„Zdd„Zdd„Zdd „Zd d „Zd d „Zdd„Zdd„Z dd„Z dd„Z dd„Z d/dd„Z d0dd„Zdd„Zd d!„Zd"d#„Zd$d%„Zd&d'„Zd(d)„Zd*d+„Zd1d-d.„Zd,S)2é)ÚImagecCstjd|j|ƒS)zVFill a channel with a given grey level. :rtype: :py:class:`~PIL.Image.Image` ÚL)rÚnewÚsize)ÚimageÚvalue©rú//tmp/tmp5hum_rxs/lib64/python/PIL/ImageChops.pyÚconstantsr cCs|jƒS)ziCopy a channel. Alias for :py:meth:`PIL.Image.Image.copy`. :rtype: :py:class:`~PIL.Image.Image` )Úcopy)rrrr Ú duplicatesr cCs|jƒ|j|jjƒƒS)z… Invert an image (channel). .. code-block:: python out = MAX - image :rtype: :py:class:`~PIL.Image.Image` )ÚloadÚ_newÚimZ chop_invert)rrrr Úinvert's rcCs$|jƒ|jƒ|j|jj|jƒƒS)zÖ Compares the two images, pixel by pixel, and returns a new image containing the lighter values. .. code-block:: python out = max(image1, image2) :rtype: :py:class:`~PIL.Image.Image` )r rrZ chop_lighter)Úimage1Úimage2rrr Úlighter6s rcCs$|jƒ|jƒ|j|jj|jƒƒS)zÕ Compares the two images, pixel by pixel, and returns a new image containing the darker values. .. code-block:: python out = min(image1, image2) :rtype: :py:class:`~PIL.Image.Image` )r rrZ chop_darker)rrrrr ÚdarkerGs rcCs$|jƒ|jƒ|j|jj|jƒƒS)zË Returns the absolute value of the pixel-by-pixel difference between the two images. .. code-block:: python out = abs(image1 - image2) :rtype: :py:class:`~PIL.Image.Image` )r rrZchop_difference)rrrrr Ú differenceXs rcCs$|jƒ|jƒ|j|jj|jƒƒS)a6 Superimposes two images on top of each other. If you multiply an image with a solid black image, the result is black. If you multiply with a solid white image, the image is unaffected. .. code-block:: python out = image1 * image2 / MAX :rtype: :py:class:`~PIL.Image.Image` )r rrZ chop_multiply)rrrrr ÚmultiplyisrcCs$|jƒ|jƒ|j|jj|jƒƒS)zà Superimposes two inverted images on top of each other. .. code-block:: python out = MAX - ((MAX - image1) * (MAX - image2) / MAX) :rtype: :py:class:`~PIL.Image.Image` )r rrZ chop_screen)rrrrr Úscreen|s rcCs$|jƒ|jƒ|j|jj|jƒƒS)z Superimposes two images on top of each other using the Soft Light algorithm :rtype: :py:class:`~PIL.Image.Image` )r rrZchop_soft_light)rrrrr Ú soft_lightŒsrcCs$|jƒ|jƒ|j|jj|jƒƒS)z Superimposes two images on top of each other using the Hard Light algorithm :rtype: :py:class:`~PIL.Image.Image` )r rrZchop_hard_light)rrrrr Ú hard_light˜srcCs$|jƒ|jƒ|j|jj|jƒƒS)z| Superimposes two images on top of each other using the Overlay algorithm :rtype: :py:class:`~PIL.Image.Image` )r rrZ chop_overlay)rrrrr Úoverlay¤srçð?écCs(|jƒ|jƒ|j|jj|j||ƒƒS)a Adds two images, dividing the result by scale and adding the offset. If omitted, scale defaults to 1.0, and offset to 0.0. .. code-block:: python out = ((image1 + image2) / scale + offset) :rtype: :py:class:`~PIL.Image.Image` )r rrZchop_add)rrÚscaleÚoffsetrrr Úadd°s rcCs(|jƒ|jƒ|j|jj|j||ƒƒS)a Subtracts two images, dividing the result by scale and adding the offset. If omitted, scale defaults to 1.0, and offset to 0.0. .. code-block:: python out = ((image1 - image2) / scale + offset) :rtype: :py:class:`~PIL.Image.Image` )r rrZ chop_subtract)rrrrrrr ÚsubtractÁs r cCs$|jƒ|jƒ|j|jj|jƒƒS)z Add two images, without clipping the result. .. code-block:: python out = ((image1 + image2) % MAX) :rtype: :py:class:`~PIL.Image.Image` )r rrZchop_add_modulo)rrrrr Ú add_moduloÒs r!cCs$|jƒ|jƒ|j|jj|jƒƒS)z¥Subtract two images, without clipping the result. .. code-block:: python out = ((image1 - image2) % MAX) :rtype: :py:class:`~PIL.Image.Image` )r rrZchop_subtract_modulo)rrrrr Úsubtract_moduloás r"cCs$|jƒ|jƒ|j|jj|jƒƒS)aƒLogical AND between two images. Both of the images must have mode "1". If you would like to perform a logical AND on an image with a mode other than "1", try :py:meth:`~PIL.ImageChops.multiply` instead, using a black-and-white mask as the second image. .. code-block:: python out = ((image1 and image2) % MAX) :rtype: :py:class:`~PIL.Image.Image` )r rrZchop_and)rrrrr Ú logical_andðsr#cCs$|jƒ|jƒ|j|jj|jƒƒS)z¿Logical OR between two images. Both of the images must have mode "1". .. code-block:: python out = ((image1 or image2) % MAX) :rtype: :py:class:`~PIL.Image.Image` )r rrZchop_or)rrrrr Ú logical_ors r$cCs$|jƒ|jƒ|j|jj|jƒƒS)zÌLogical XOR between two images. Both of the images must have mode "1". .. code-block:: python out = ((bool(image1) != bool(image2)) % MAX) :rtype: :py:class:`~PIL.Image.Image` )r rrZchop_xor)rrrrr Ú logical_xors r%cCstj|||ƒS)z‰Blend images using constant transparency weight. Alias for :py:func:`PIL.Image.blend`. :rtype: :py:class:`~PIL.Image.Image` )rÚblend)rrÚalpharrr r&&sr&cCstj|||ƒS)z†Create composite using transparency mask. Alias for :py:func:`PIL.Image.composite`. :rtype: :py:class:`~PIL.Image.Image` )rÚ composite)rrÚmaskrrr r(0sr(NcCs(|dkr |}|jƒ|j|jj||ƒƒS)a~Returns a copy of the image where data has been offset by the given distances. Data wraps around the edges. If ``yoffset`` is omitted, it is assumed to be equal to ``xoffset``. :param xoffset: The horizontal distance. :param yoffset: The vertical distance. If omitted, both distances are set to the same value. :rtype: :py:class:`~PIL.Image.Image` N)r rrr)rZxoffsetZyoffsetrrr r:s r)rr)rr)N)Úrr r rrrrrrrrrrr r!r"r#r$r%r&r(rrrrr Ús*