Files
intellecton/venv/lib/python3.12/site-packages/PIL/__pycache__/WalImageFile.cpython-312.pyc
T

54 lines
4.1 KiB
Plaintext
Raw Normal View History

Ë
ß¼j‚ãó~—dZddlmZddlmZddlmZmZddlm Z
ddl m Z Gd„d ej«Z
d
d
„Zd Zy )a�
This reader is based on the specification available from:
https://www.flipcode.com/archives/Quake_2_BSP_File_Format.shtml
and has been tested with a few sample files found using google.
.. note::
This format cannot be automatically recognized, so the reader
is not registered for use with :py:func:`PIL.Image.open()`.
To open a WAL file, use the :py:func:`PIL.WalImageFile.open()` function instead.
é)Ú annotations)ÚIOé)ÚImageÚ ImageFile)Úi32le)ÚStrOrBytesPathcó$—eZdZdZdZdd„Zdd„Zy)Ú WalImageFileÚWALzQuake2 TexturecóÈ—d|_|j€J‚|jjd«}t|d«t|d«f|_t j |j«t|d«}|jj|«|ddjdd«d|jd <|d
d jdd«dx}r||jd <yy)
NÚPédé é$é(órrÚnameé8éXÚ next_name) Ú_modeÚfpÚreadÚi32Ú_sizerÚ_decompression_bomb_checkÚsizeÚseekÚsplitÚinfo)ÚselfÚheaderÚoffsetrs úS/home/antigravity/intellecton/venv/lib/python3.12/site-packages/PIL/WalImageFile.pyÚ_openzWalImageFile._open'sՀ؈Œ
ð�w‰wÐ"Ð"Ð"Ø—‘—‘Ð/Ó0ˆÜ˜ “_¤c¨&°"£oÐ5ˆŒ
Ü
×'Ñ'¨¯ © Ô2ô�V˜R“ˆØ �‰� ‰ �VÔð# 3 B˜K×-Ñ-¨e°QÓ7¸Ñ:ˆ� ‰ �&ÑØ˜r GÐ,×2Ñ2°5¸!Ó<¸QÑ?Ð ?ˆ9Ð ?Ø%.ˆD�I‰I�kÒ "ð @ócóž—|j€£|j€J‚tjj |j
|j «|_|j|jj|j d|j dz««|jt«tjj|«S)Nrr)
Ú_imrrÚcoreÚnewÚmoderÚimÚ frombytesrÚ
putpaletteÚ
quake2paletteÚload)r"s r%r1zWalImageFile.load9s‰€Ø �8‰8Ð Ø—7‘7Ð&Ð &Ð&Ü—j‘j—n‘n T§Y¡Y°· ± Ó:ˆDŒGØ �N‰N˜4Ÿ7™7Ÿ<™<¨¯ © °!© °t·y±yÀ±|Ñ(CÓDÔ EØ �O‰OœMÔ *Ü�{‰{×Ñ Ó%Ð%r'N)ÚreturnÚNone)r2zImage.core.PixelAccess | None)Ú__name__Ú
__module__Ú __qualname__ÚformatÚformat_descriptionr&r1©r'r%r r #s„Ø
€FØ)Ðó/ô$&r'r có—t|«S)a2
Load texture from a Quake2 WAL texture file.
By default, a Quake2 standard palette is attached to the texture.
To override the palette, use the :py:func:`PIL.Image.Image.putpalette()` method.
:param filename: WAL file name, or an opened file handle.
:returns: An image instance.
)r )Úfilenames r%Úopenr<Bs€ô ˜Ó !Ð!r's """&&&))),,,///222555777:::<<<$" 


  


##&""%" #!"  
-( )$'"%8.1),%& <07,3(-$(" 
10.,
* '
%!
   



)#'!& %#!