# VESA

VESA is the Video Electronics Standard Association and they created VBE, the
VESA BIOS Extension standard. VESA 1.2 was released in 1991 and is the version
that really caught on, so that's our baseline. VESA is much easier to work with
than VGA, so that's why we prefer it.

The driver lives in drv/pc/vesa.fs

After you've loaded it, you can get general VESA information with ".vesa" and
you can list available modes with ".vesamodes". The output is
"<id> width/height/bpp". A "*" at the end indicates that this mode is a "linear"
mode.

There's a big difference between VESA 1.2 and VESA 2.0: the presence of linear
buffer modes. A "regular" mode requires bank switching to access the totality of
the memory for that mode, which comes in 64K banks. It's a hassle to manage.
Linear modes provide a contiguous memory area, which is much nicer. When
available, you always want linear mode, it's much faster.

TODO: in fact, at this time, only linear mode is supported. bank switching
support incoming...

This driver provides the VESAScreen struct which you can instantiate and plug
into the "screen" global variable from sys/screen. Example:

    f<< /sys/screen.fs
    f<< /drv/pc/vesa.fs
    VESAScreen :new rebind' screen

The driver also has the "vesamode" variable, which defaults to $112
(640x480x24), indicating which mode ID will be used on "screen :activate".
