summaryrefslogtreecommitdiff
path: root/com32/lua/test/vesa.lua
diff options
context:
space:
mode:
authorMarcel Ritter <unrzl1@linux.rrze.uni-erlangen.de>2008-12-15 16:17:09 +0100
committerMarcel Ritter <unrzl1@linux.rrze.uni-erlangen.de>2008-12-15 16:17:09 +0100
commit68c0e55e8f6f9dc22f5c8c1a8930b616a101b13a (patch)
tree3847780d1827e5d9309fc410be7f615874d456d5 /com32/lua/test/vesa.lua
parentc70f91446e978a8ea113b00de33d8d862d5d0d58 (diff)
downloadsyslinux-68c0e55e8f6f9dc22f5c8c1a8930b616a101b13a.tar.gz
COM32: lua - add vesa functions (only mode listing right now)
Diffstat (limited to 'com32/lua/test/vesa.lua')
-rw-r--r--com32/lua/test/vesa.lua11
1 files changed, 11 insertions, 0 deletions
diff --git a/com32/lua/test/vesa.lua b/com32/lua/test/vesa.lua
new file mode 100644
index 00000000..4bc41fbc
--- /dev/null
+++ b/com32/lua/test/vesa.lua
@@ -0,0 +1,11 @@
+-- get nice output
+printf = function(s,...)
+ return io.write(s:format(...))
+ end
+
+modes = vesa.getmodes()
+
+for mind,mode in pairs(modes) do
+ printf("%04x: %dx%dx%d\n", mode['mode'], mode['hres'], mode['vres'], mode['bpp'])
+end
+