+
    UBi                    b    ^ RI Ht ^RIHt Rt]'       d   ^ RIHt  ! R R4      tR
R R	 lltR# )    )annotations)ImageF)Callablec                  J    ] tR t^tRtR R ltR R ltR R ltR R	 ltR
t	R# )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                    V ^8  d   QhRRRR/# )   imImage.ImagereturnNone )formats   "6/usr/lib/python3.14/site-packages/PIL/ImageSequence.py__annotate__Iterator.__annotate__&   s     : :; :4 :    c                	    \        VR 4      '       g   Rp\        V4      hWn        \        V P                  R^ 4      V n        R# )seekzim must have seek method
_min_frameN)hasattrAttributeErrorr
   getattrposition)selfr
   msgs   && r   __init__Iterator.__init__&   s8    r6"",C %%q9r   c                    V ^8  d   QhRRRR/# )r	   ixintr   r   r   )r   s   "r   r   r   -   s     ) )c )k )r   c                	     V P                   P                  V4       V P                   #   \         d   pR p\        T4      ThRp?ii ; i)end of sequenceN)r
   r   EOFError
IndexError)r   r    er   s   &&  r   __getitem__Iterator.__getitem__-   sA    	)GGLL77N 	)#CS/q(	)s   &) AAAc                   V ^8  d   QhRR/# )r	   r   r   r   )r   s   "r   r   r   5   s      ( r   c                	    V # Nr   )r   s   &r   __iter__Iterator.__iter__5   s    r   c                   V ^8  d   QhRR/# )r	   r   r   r   )r   s   "r   r   r   8   s     , ,+ ,r   c                	     V P                   P                  V P                  4       V ;P                  ^,          un        V P                   #   \         d   pRp\	        T4      ThRp?ii ; i)   r#   N)r
   r   r   r$   StopIteration)r   r&   r   s   &  r   __next__Iterator.__next__8   sT    	,GGLL'MMQM77N 	,#C$!+	,s   A	A A*A%%A*)r
   r   N)
__name__
__module____qualname____firstlineno____doc__r   r'   r,   r2   __static_attributes__r   r   r   r   r      s     	:), ,r   r   Nc               $    V ^8  d   QhRRRRRR/# )r	   r
   zImage.Image | list[Image.Image]funcz+Callable[[Image.Image], Image.Image] | Noner   zlist[Image.Image]r   )r   s   "r   r   r   B   s&     5 5'5
55 5r   c                @   \        V \        4      '       g   V .p . pV  FS  pVP                  4       pT\        V4       Uu. uF  qUP	                  4       NK  	  up,          pVP                  V4       KU  	  V'       d   V U u. uF
  q! V 4      NK  	  up # T# u upi u up i )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
   r;   ims
imSequencecurrentim_frames   &&    r   
all_framesrE   B   s     b$T
C
//#0DE0DH0DEE   (,s#sDHs#44 F $s   BBr+   )	
__future__r    r   TYPE_CHECKINGcollections.abcr   r   rE   r   r   r   <module>rJ      s-   " # (%, %,P5 5r   