diff options
author | ftrvxmtrx <devnull@localhost> | 2014-12-26 17:01:58 +0100 |
---|---|---|
committer | ftrvxmtrx <devnull@localhost> | 2014-12-26 17:01:58 +0100 |
commit | 0d5b33a9e821ab0c3230bd25596b6567f2b28cd6 (patch) | |
tree | d3d87fc9131670e7625016f742561299114e6c4b /sys/src/cmd/aux/vga/main.c | |
parent | 04ec990b670c761866da5bb0ab344da3407e78ca (diff) |
aux/vga: scaling modes for VESA
Diffstat (limited to 'sys/src/cmd/aux/vga/main.c')
-rw-r--r-- | sys/src/cmd/aux/vga/main.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/sys/src/cmd/aux/vga/main.c b/sys/src/cmd/aux/vga/main.c index a42e8e648..9b4de02b0 100644 --- a/sys/src/cmd/aux/vga/main.c +++ b/sys/src/cmd/aux/vga/main.c @@ -149,7 +149,7 @@ chanstr[32+1] = { static void usage(void) { - fprint(2, "usage: aux/vga [ -BcdilpvV ] [ -b bios-id ] [ -m monitor ] [ -x db ] [ mode [ virtualsize ] ]\n"); + fprint(2, "usage: aux/vga [ -BcdilpvV ] [ -b bios-id ] [ -m monitor ] [-s scaling] [ -x db ] [ mode [ virtualsize ] ]\n"); exits("usage"); } @@ -157,7 +157,7 @@ void main(int argc, char** argv) { char *bios, buf[256], sizeb[256], *p, *vsize, *psize; - char *type, *vtype; + char *type, *vtype, *scaling; int virtual, len; Ctlr *ctlr; Vga *vga; @@ -169,6 +169,7 @@ main(int argc, char** argv) if((type = getenv("monitor")) == 0) type = "vga"; psize = vsize = "640x480x8"; + scaling = nil; ARGBEGIN{ default: @@ -204,6 +205,9 @@ main(int argc, char** argv) */ rflag++; break; + case 's': + scaling = EARGF(usage()); + break; case 'v': vflag = 1; break; @@ -467,6 +471,11 @@ main(int argc, char** argv) } } + if(scaling != nil){ + if(vga->vesa) + vesa.scaling(vga, vga->vesa, scaling); + } + trace("main->exits\n"); exits(0); } |