ReactOS 0.4.16-dev-297-gc569aee
vbe.h
Go to the documentation of this file.
1/*
2 * COPYRIGHT: GPLv2+ - See COPYING in the top level directory
3 * PROJECT: ReactOS Virtual DOS Machine
4 * FILE: subsystems/mvdm/ntvdm/bios/bios32/vbe.h
5 * PURPOSE: VDM VESA BIOS Extensions (for the Cirrus CL-GD5434 emulated card)
6 * PROGRAMMERS: Aleksandar Andrejevic <theflash AT sdf DOT lonestar DOT org>
7 */
8
9#ifndef _VBE_H_
10#define _VBE_H_
11
12#include "hardware/video/svga.h"
13
14/* DEFINITIONS ****************************************************************/
15
16#define OEM_NAME "Cirrus Logic GD-5434 VGA"
17#define OEM_NAME_PTR 0xF01D5091
18
19#define VBE_MODE_COUNT 40
20
21/* VBE Mode Attribute Flags */
22#define VBE_MODE_SUPPORTED (1 << 0)
23#define VBE_MODE_OPTIONAL_INFO (1 << 1)
24#define VBE_MODE_BIOS_SUPPORT (1 << 2)
25#define VBE_MODE_COLOR (1 << 3)
26#define VBE_MODE_GRAPHICS (1 << 4)
27
28/* VBE Window Attribute Flags */
29#define VBE_WINDOW_EXISTS (1 << 0)
30#define VBE_WINDOW_READABLE (1 << 1)
31#define VBE_WINDOW_WRITABLE (1 << 2)
32
33/* VBE Memory Models */
34#define VBE_MODEL_TEXT 0
35#define VBE_MODEL_CGA 1
36#define VBE_MODEL_HGC 2
37#define VBE_MODEL_EGA 3
38#define VBE_MODEL_PACKED 4
39#define VBE_MODEL_UNCHAINED 5
40#define VBE_MODEL_DIRECT 6
41#define VBE_MODEL_YUV 7
42
43#pragma pack(push, 1)
44
45typedef struct _VBE_INFORMATION
46{
55
56C_ASSERT(sizeof(VBE_INFORMATION) == 256);
57
58typedef struct _VBE_MODE_INFO
59{
90
91C_ASSERT(sizeof(VBE_MODE_INFO) % sizeof(WORD) == 0);
92
93typedef const struct _VBE_MODE_INFO *PCVBE_MODE_INFO;
94
95#pragma pack(pop)
96
97typedef struct _VBE_MODE
98{
104
105typedef const struct _VBE_MODE *PCVBE_MODE;
106
107/* FUNCTIONS ******************************************************************/
108
113
114#endif // _VBE_H_
unsigned char BOOLEAN
unsigned long DWORD
Definition: ntddk_ex.h:95
unsigned short WORD
Definition: ntddk_ex.h:93
#define C_ASSERT(e)
Definition: intsafe.h:73
WORD ModeListBuffer[118]
Definition: vbe.h:53
WORD Version
Definition: vbe.h:48
WORD VideoMemory
Definition: vbe.h:52
DWORD Signature
Definition: vbe.h:47
DWORD OemName
Definition: vbe.h:49
DWORD Capabilities
Definition: vbe.h:50
DWORD ModeList
Definition: vbe.h:51
BYTE ReservedMaskSize
Definition: vbe.h:86
WORD WindowGranularity
Definition: vbe.h:63
BYTE GreenFieldPosition
Definition: vbe.h:83
BYTE BankSize
Definition: vbe.h:77
WORD WindowSegmentA
Definition: vbe.h:65
WORD Width
Definition: vbe.h:69
BYTE GreenMaskSize
Definition: vbe.h:82
BYTE ImagePages
Definition: vbe.h:78
BYTE WindowAttrB
Definition: vbe.h:62
BYTE RedMaskSize
Definition: vbe.h:80
WORD WindowSize
Definition: vbe.h:64
WORD Height
Definition: vbe.h:70
BYTE RedFieldPosition
Definition: vbe.h:81
BYTE CellHeight
Definition: vbe.h:72
BYTE BlueMaskSize
Definition: vbe.h:84
BYTE DirectColorInfo
Definition: vbe.h:88
BYTE BitsPerPixel
Definition: vbe.h:74
BYTE MemoryModel
Definition: vbe.h:76
BYTE BlueFieldPosition
Definition: vbe.h:85
WORD Attributes
Definition: vbe.h:60
BYTE Reserved
Definition: vbe.h:79
BYTE CellWidth
Definition: vbe.h:71
BYTE NumPlanes
Definition: vbe.h:73
WORD WindowSegmentB
Definition: vbe.h:66
BYTE ReservedFieldPosition
Definition: vbe.h:87
BYTE WindowAttrA
Definition: vbe.h:61
DWORD WindowPosFunc
Definition: vbe.h:67
WORD BytesPerScanline
Definition: vbe.h:68
BYTE NumBanks
Definition: vbe.h:75
Definition: vbe.h:98
PCVBE_MODE_INFO Info
Definition: vbe.h:101
WORD VesaNumber
Definition: vbe.h:100
BYTE Number
Definition: vbe.h:99
PSVGA_REGISTERS Registers
Definition: vbe.h:102
struct _VBE_MODE_INFO VBE_MODE_INFO
const struct _VBE_MODE * PCVBE_MODE
Definition: vbe.h:105
struct _VBE_MODE * PVBE_MODE
struct _VBE_INFORMATION VBE_INFORMATION
VOID WINAPI VbeResetExtendedRegisters(VOID)
Definition: vbe.c:380
struct _VBE_INFORMATION * PVBE_INFORMATION
const struct _VBE_MODE_INFO * PCVBE_MODE_INFO
Definition: vbe.h:93
BOOLEAN VbeInitialize(VOID)
Definition: vbe.c:763
BOOLEAN WINAPI VbeSetExtendedVideoMode(BYTE ModeNumber)
Definition: vbe.c:356
struct _VBE_MODE VBE_MODE
struct _VBE_MODE_INFO * PVBE_MODE_INFO
VOID WINAPI VbeService(LPWORD Stack)
Definition: vbe.c:472
uint16_t * LPWORD
Definition: typedefs.h:56
_In_ WDFREQUEST _In_ PIO_STACK_LOCATION Stack
Definition: wdfrequest.h:639
#define WINAPI
Definition: msvc.h:6
unsigned char BYTE
Definition: xxhash.c:193