File: //home/arjun/projects/env/lib64/python3.10/site-packages/PIL/__pycache__/_binary.cpython-310.pyc
o
we� � @ s� d Z ddlmZmZ dd� Zdd� Zddd�Zdd d
�Zddd�Zdd
d�Z ddd�Z
ddd�Zddd�Zdd� Z
dd� Zdd� Zdd� ZdS )z%Binary input/output support routines.� )�pack�unpack_fromc C s | j tu r| S | d S )Nr )� __class__�int)�c� r �D/home/arjun/projects/env/lib/python3.10/site-packages/PIL/_binary.py�i8 s r c C s t | d@ f�S )N� )�bytes��ir r r �o8 s r c C � t d| |�d S )z�
Converts a 2-bytes (16 bits) string to an unsigned integer.
:param c: string containing bytes to convert
:param o: offset of bytes to convert in string
�<Hr �r �r �or r r �i16le � r c C r )z�
Converts a 2-bytes (16 bits) string to a signed integer.
:param c: string containing bytes to convert
:param o: offset of bytes to convert in string
z<hr r r r r r �si16le( r r c C r )z�
Converts a 2-bytes (16 bits) string to a signed integer, big endian.
:param c: string containing bytes to convert
:param o: offset of bytes to convert in string
z>hr r r r r r �si16be2 r r c C r )z�
Converts a 4-bytes (32 bits) string to an unsigned integer.
:param c: string containing bytes to convert
:param o: offset of bytes to convert in string
�<Ir r r r r r �i32le<