diff options
author | Loek Le Blansch <loek@pipeframe.xyz> | 2024-10-05 20:19:56 +0200 |
---|---|---|
committer | Loek Le Blansch <loek@pipeframe.xyz> | 2024-10-05 20:19:56 +0200 |
commit | 52971b9a2180ca3a54eb25ab49773e818cb8ae15 (patch) | |
tree | f6645d767661f6d953679456e3bd3348c915e5c8 /experiments | |
parent | e5381daf8cfa640494aaedaa99541eb58ec651f4 (diff) |
more debugging fiddled messages being ignored
Diffstat (limited to 'experiments')
-rw-r--r-- | experiments/conv/makefile | 5 | ||||
-rwxr-xr-x | experiments/conv/png2pc | 7 |
2 files changed, 10 insertions, 2 deletions
diff --git a/experiments/conv/makefile b/experiments/conv/makefile index ae2f70d..2a513c0 100644 --- a/experiments/conv/makefile +++ b/experiments/conv/makefile @@ -1,5 +1,8 @@ %.png: %.bin - ./pc2png $< + venv/bin/python3 pc2png $< + +%.bin: %.png + venv/bin/python3 png2pc $< %.h: %.bin ./bin2h $< > $@ diff --git a/experiments/conv/png2pc b/experiments/conv/png2pc index d1eaab8..21b3b29 100755 --- a/experiments/conv/png2pc +++ b/experiments/conv/png2pc @@ -1,7 +1,7 @@ #!/bin/python3 import itertools import io -from PIL import Image +from PIL import Image, ImageDraw from consts import * from shared import main @@ -37,6 +37,11 @@ def png2pc(data): img = img.convert('RGB') img = img.quantize(palette=palette_img) + draw = ImageDraw.Draw(img) + draw.rectangle(((0, 0), (24, img.height)), fill=0) + draw.rectangle(((252, 0), (256, img.height)), fill=0) + draw.rectangle(((24, 0), (79, 16)), fill=0) + output = b"" for tile_idx in range(tile_count): tile = ( |