diff options
Diffstat (limited to 'img')
-rw-r--r-- | img/driver.dat | 1 | ||||
-rw-r--r-- | img/driver.lua | 9 | ||||
-rw-r--r-- | img/shitty_disp.lua | 2 |
3 files changed, 12 insertions, 0 deletions
diff --git a/img/driver.dat b/img/driver.dat new file mode 100644 index 0000000..228280a --- /dev/null +++ b/img/driver.dat @@ -0,0 +1 @@ +dep util img/shitty_disp img/load_pnm diff --git a/img/driver.lua b/img/driver.lua new file mode 100644 index 0000000..808399d --- /dev/null +++ b/img/driver.lua @@ -0,0 +1,9 @@ +local load_pnm = require("img.load_pnm").load +local shitty_disp = require("img.shitty_disp").disp +local perr = require("util").perr + +local file,err = fs.open("/J.pbm","r") +perr(err,"fs.open") +local ff = file.readAll() +local img = load_pnm(ff) +shitty_disp(img) diff --git a/img/shitty_disp.lua b/img/shitty_disp.lua index f0a1f07..c2077db 100644 --- a/img/shitty_disp.lua +++ b/img/shitty_disp.lua @@ -39,3 +39,5 @@ local function disp(R,img,scrx,scry,w,h,imgx,imgy) end end end + +return {disp=disp} |