ImageDecoder
¶Methods:
decode
(file, filename)Decode the given file object and return an instance of Image. decode_animation
(file, filename)Decode the given file object and return an instance of Animation. get_animation_file_extensions
()Return a list of accepted file extensions, e.g. get_file_extensions
()Return a list of accepted file extensions, e.g.
ImageDecoder.
decode
(file, filename)¶Decode the given file object and return an instance of Image. Throws ImageDecodeException if there is an error. filename can be a file type hint.
ImageDecoder.
decode_animation
(file, filename)¶Decode the given file object and return an instance of Animation. Throws ImageDecodeException if there is an error. filename can be a file type hint.
ImageDecoder.
get_animation_file_extensions
()¶Return a list of accepted file extensions, e.g. [‘.gif’, ‘.flc’] Lower-case only.
ImageDecoder.
get_file_extensions
()¶Return a list of accepted file extensions, e.g. [‘.png’, ‘.bmp’] Lower-case only.