← Back
Editing: ImageTransform.cpython-311.pyc
� �"�cC � � � d dl mZ G d� dej � � Z G d� de� � Z G d� de� � Z G d� d e� � Z G d � de� � ZdS ) � )�Imagec � � e Zd Zd� Zd� Zd� ZdS )� Transformc � � || _ d S �N)�data)�selfr s �4/usr/lib/python3/dist-packages/PIL/ImageTransform.py�__init__zTransform.__init__ s � ��� � � � c � � | j | j fS r )�methodr )r s r �getdatazTransform.getdata s � ��{�D�I�%�%r c �P � | � � � \ }} |j |||fi |��S r )r � transform)r �size�image�optionsr r s r r zTransform.transform s1 � ��|�|�~�~�����u��t�V�T�=�=�W�=�=�=r N)�__name__� __module__�__qualname__r r r � r r r r sA � � � � � �� � �&� &� &�>� >� >� >� >r r c �* � e Zd ZdZej j ZdS )�AffineTransformaS Define an affine image transform. This function takes a 6-tuple (a, b, c, d, e, f) which contain the first two rows from an affine transform matrix. For each pixel (x, y) in the output image, the new value is taken from a position (a x + b y + c, d x + e y + f) in the input image, rounded to nearest pixel. This function can be used to scale, translate, rotate, and shear the original image. See :py:meth:`~PIL.Image.Image.transform` :param matrix: A 6-tuple (a, b, c, d, e, f) containing the first two rows from an affine transform matrix. N)r r r �__doc__r r �AFFINEr r r r r r s$ � � � � � �� �"