Anonymous user
VESA Video Modes: Difference between revisions
no edit summary
[unchecked revision] | [unchecked revision] |
No edit summary |
No edit summary |
||
Line 5:
You'll want to look in the VESA VBE docs for these functions:
;INT 0x10, AX=0x4F00
<pre>
struct vbeControllerInfo {
char signature[4]; // == "VESA"
Line 19 ⟶ 20:
v86_bios(0x10, {ax:0x4f00, es:SEG(vib), di:OFF(vib)},&out);
if (out.ax!=0x004f) die("something wrong with VBE get info");
</
;INT 0x10, AX=0x4F01
<pre>
struct vbeModeInfo {
Line 49 ⟶ 51:
short reserved2;
};
</
;__INT 0x10, AX=0x4F02__: Set Video Mode. Call this with the mode number you decide to use.
For VBE to work in Bochs you need the "VGABIOS-lgpl" BIOS and have a version of Bochs that was compiled with the "--enable-vbe" option... See [Vesa Information in Bochs| Forum:6311] thread for more info
Here's a sample code, assuming you have a VirtualMonitor already ... Basically, you will scan the 'modes list' referenced by the vbeInfoBlock.videomodes[] and then call 'get mode info' for each mode. You can then compare width, height and colordepth of each mode with the desired one.
<pre>
UInt16 findMode(int x, int y, int d)
Line 106 ⟶ 109:
return best;
}
</
==See Also==
===Threads===
[[Category:Video]]
▲Initial Thread: [VESA, higher modes|Forum:6379], reply by Dreamsmith (aka DaidalosGuy)
|