From e46b63cca225d6780f00c997aecb7087c866a8cc Mon Sep 17 00:00:00 2001 From: Tauwasser Date: Sun, 28 Feb 2016 23:14:53 +0100 Subject: gfx.py: PNGs should be opened in binary mode PNG files were opened as text files, thus the signature 0x0D 0x0A bytes were swallowed depending on OS. Signed-off-by: Tauwasser --- pokemontools/gfx.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pokemontools/gfx.py b/pokemontools/gfx.py index a728de1..f93553d 100644 --- a/pokemontools/gfx.py +++ b/pokemontools/gfx.py @@ -634,7 +634,7 @@ def png_to_2bpp(filein, **kwargs): arguments.update(kwargs) if type(filein) is str: - filein = open(filein) + filein = open(filein, 'rb') assert type(filein) is file -- cgit v1.2.3