diff options
author | lonkaars <loek@pipeframe.xyz> | 2022-12-20 12:06:33 +0100 |
---|---|---|
committer | lonkaars <loek@pipeframe.xyz> | 2022-12-20 12:06:33 +0100 |
commit | da810896f4c249d61f00e9e413d82dad2ad2058e (patch) | |
tree | b6f19cb96ec330a843cb8f257a5bb528122e5f89 /src | |
parent | bfb6b4cf92747d5a6457ff1a1d6a85cbef7b019b (diff) |
update makefile for calling python script
Diffstat (limited to 'src')
-rwxr-xr-x | src/bitmap-ball.py | 4 | ||||
-rw-r--r-- | src/makefile | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/bitmap-ball.py b/src/bitmap-ball.py index d28609c..4d5be0c 100755 --- a/src/bitmap-ball.py +++ b/src/bitmap-ball.py @@ -1,14 +1,14 @@ #!/bin/python3 from PIL import Image -import os +import sys WIDTH = 10 HEIGHT = 10 # return array of 12-bit color values (0bRRRGGGBBB) def pixeldata(): - image = Image.open("./ball.png") + image = Image.open(sys.argv[-1]) # use last argument as input image file pixels = image.load() pixarr = [] for x in range(WIDTH): diff --git a/src/makefile b/src/makefile index 2906e87..5dff86d 100644 --- a/src/makefile +++ b/src/makefile @@ -1,6 +1,6 @@ pixeldata-ball.vhd: pixeldata-ball-top.vhd bitmap-ball.vhd pixeldata-ball-bottom.vhd cat $^ > $@ -bitmap-ball.vhd: bitmap-ball.py - python3 $< > $@ +bitmap-ball.vhd: ball.png + python3 bitmap-ball.py $< > $@ |