Ë
    ™2ÚiP  ã                   ó    —  G d „ d«      Z dd„Zy)c                   ó(   — e Zd ZdZd„ Zd„ Zd„ Zd„ Zy)ÚIteratora-  
    This class implements an iterator object that can be used to loop
    over an image sequence.

    You can use the ``[]`` operator to access elements by index. This operator
    will raise an :py:exc:`IndexError` if you try to access a nonexistent
    frame.

    :param im: An image object.
    c                 ó|   — t        |d«      sd}t        |«      ‚|| _        t        | j                  dd«      | _        y )NÚseekzim must have seek methodÚ
_min_frameé    )ÚhasattrÚAttributeErrorÚimÚgetattrÚposition)Úselfr
   Úmsgs      úH/var/www/html/acx/venv/lib/python3.12/site-packages/PIL/ImageSequence.pyÚ__init__zIterator.__init__   s7   € Ü�r˜6Ô"Ø,ˆCÜ  Ó%Ð%ØˆŒÜ §¡¨°qÓ9ˆ�ó    c                 ó‚   — 	 | j                   j                  |«       | j                   S # t        $ r}t        |‚d }~ww xY w©N)r
   r   ÚEOFErrorÚ
IndexError)r   ÚixÚes      r   Ú__getitem__zIterator.__getitem__&   s8   € ð	$Ø�G‰G�L‰L˜ÔØ—7‘7ˆNøÜò 	$Ü !Ð#ûð	$ús   ‚&) ©	>²9¹>c                 ó   — | S r   © )r   s    r   Ú__iter__zIterator.__iter__-   s   € Øˆr   c                 óÀ   — 	 | j                   j                  | j                  «       | xj                  dz  c_        | j                   S # t        $ r}t        |‚d }~ww xY w)Né   )r
   r   r   r   ÚStopIteration)r   r   s     r   Ú__next__zIterator.__next__0   sJ   € ð	'Ø�G‰G�L‰L˜Ÿ™Ô'Ø�MŠM˜QÑ�MØ—7‘7ˆNøÜò 	'Ü QÐ&ûð	'ús   ‚AA Á	AÁAÁAN)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r   r   r   r   r   r   r   r      s   „ ñ	ò:ò$òó'r   r   Nc                 ó  — t        | t        «      s| g} g }| D ]M  }|j                  «       }|t        |«      D �cg c]  }|j	                  «       ‘Œ c}z  }|j                  |«       ŒO |r|D � cg c]
  }  || «      ‘Œ c} S |S c c}w c c} w )a  
    Applies a given function to all frames in an image or a list of images.
    The frames are returned as a list of separate images.

    :param im: An image, or a list of images.
    :param func: The function to apply to all of the image frames.
    :returns: A list of images.
    )Ú
isinstanceÚlistÚtellr   Úcopyr   )r
   ÚfuncÚimsÚ
imSequenceÚcurrentÚim_frames         r   Ú
all_framesr.   9   sŠ   € ô �bœ$ÔØˆTˆà
€CØò !ˆ
Ø—/‘/Ó#ˆà´¸Ó0DÖE H�—‘•ÒEÑEˆà�‰˜Õ ð!ñ (,˜sÖ#˜‰D��HÒ#Ð4°Ð4ùò Fùò $s   ¹BÁ.Br   )r   r.   r   r   r   ú<module>r/      s   ð÷&#'ñ #'ôL5r   