Bochs VBE Extensions: Difference between revisions
Jump to navigation
Jump to search
[unchecked revision] | [unchecked revision] |
Content deleted Content added
No edit summary |
No edit summary |
||
Line 14: | Line 14: | ||
* 0xB0C3 - support for getting capabilities, support for using 8 bit DAC |
* 0xB0C3 - support for getting capabilities, support for using 8 bit DAC |
||
* 0xB0C4 - [TODO: check and describe] |
* 0xB0C4 - [TODO: check and describe] |
||
[TODO: if and when 4BPP modes are supported] |
|||
== Programming the BGA == |
== Programming the BGA == |
||
Line 60: | Line 61: | ||
=== Miscellaneous === |
=== Miscellaneous === |
||
[TODO: check and describe |
[TODO: check and describe VBE_DISPI_INDEX_VIRT_WIDTH/HEIGHT, VBE_DISPI_INDEX_X/Y_OFFSET, VBE_DISPI_GETCAPS, VBE_DISPI_8BIT_DAC] |
||
=== Example code === |
=== Example code === |
||
Line 69: | Line 70: | ||
outpw(VBE_DISPI_IOPORT_INDEX, IndexValue); |
outpw(VBE_DISPI_IOPORT_INDEX, IndexValue); |
||
outpw(VBE_DISPI_IOPORT_DATA, DataValue); |
outpw(VBE_DISPI_IOPORT_DATA, DataValue); |
||
} |
|||
unsigned short BgaReadRegister(unsigned short IndexValue) |
|||
{ |
|||
outpw(VBE_DISPI_IOPORT_INDEX, IndexValue); |
|||
return inpw(VBE_DISPI_IOPORT_DATA); |
|||
} |
|||
int BgaIsAvailable(void) |
|||
{ |
|||
return (BgaReadRegister(VBE_DISPI_INDEX_ID) == VBE_DISPI_ID4); |
|||
} |
} |
||