1 | /** @file
|
---|
2 | Type definitions related to the VBE (VESA BIOS Extension, Int10h AH=4Fh)
|
---|
3 | services GET INFORMATION (AL=00h) and GET MODE INFORMATION (AL=01h).
|
---|
4 |
|
---|
5 | For reference, see Ralf Brown's Interrupt List:
|
---|
6 | <http://www.cs.cmu.edu/~ralf/files.html>
|
---|
7 | <http://www.ctyme.com/rbrown.htm>
|
---|
8 |
|
---|
9 | Copyright (C) 2014, Red Hat, Inc.
|
---|
10 |
|
---|
11 | SPDX-License-Identifier: BSD-2-Clause-Patent
|
---|
12 | **/
|
---|
13 |
|
---|
14 | #ifndef __LEGACY_VGA_BIOS_H__
|
---|
15 | #define __LEGACY_VGA_BIOS_H__
|
---|
16 |
|
---|
17 | #include <Base.h>
|
---|
18 |
|
---|
19 | #pragma pack (1)
|
---|
20 | typedef struct {
|
---|
21 | UINT8 Signature[4];
|
---|
22 | UINT16 VesaVersion;
|
---|
23 | UINT32 OemNameAddress;
|
---|
24 | UINT32 Capabilities;
|
---|
25 | UINT32 ModeListAddress;
|
---|
26 | UINT16 VideoMem64K;
|
---|
27 | UINT16 OemSoftwareVersion;
|
---|
28 | UINT32 VendorNameAddress;
|
---|
29 | UINT32 ProductNameAddress;
|
---|
30 | UINT32 ProductRevAddress;
|
---|
31 | } VBE_INFO_BASE;
|
---|
32 |
|
---|
33 | typedef struct {
|
---|
34 | VBE_INFO_BASE Base;
|
---|
35 | UINT8 Buffer[256 - sizeof (VBE_INFO_BASE)];
|
---|
36 | } VBE_INFO;
|
---|
37 |
|
---|
38 | typedef struct {
|
---|
39 | UINT16 ModeAttr;
|
---|
40 | UINT8 WindowAAttr;
|
---|
41 | UINT8 WindowBAttr;
|
---|
42 | UINT16 WindowGranularityKB;
|
---|
43 | UINT16 WindowSizeKB;
|
---|
44 | UINT16 WindowAStartSegment;
|
---|
45 | UINT16 WindowBStartSegment;
|
---|
46 | UINT32 WindowPositioningAddress;
|
---|
47 | UINT16 BytesPerScanLine;
|
---|
48 |
|
---|
49 | UINT16 Width;
|
---|
50 | UINT16 Height;
|
---|
51 | UINT8 CharCellWidth;
|
---|
52 | UINT8 CharCellHeight;
|
---|
53 | UINT8 NumPlanes;
|
---|
54 | UINT8 BitsPerPixel;
|
---|
55 | UINT8 NumBanks;
|
---|
56 | UINT8 MemoryModel;
|
---|
57 | UINT8 BankSizeKB;
|
---|
58 | UINT8 NumImagePagesLessOne;
|
---|
59 | UINT8 Vbe3;
|
---|
60 |
|
---|
61 | UINT8 RedMaskSize;
|
---|
62 | UINT8 RedMaskPos;
|
---|
63 | UINT8 GreenMaskSize;
|
---|
64 | UINT8 GreenMaskPos;
|
---|
65 | UINT8 BlueMaskSize;
|
---|
66 | UINT8 BlueMaskPos;
|
---|
67 | UINT8 ReservedMaskSize;
|
---|
68 | UINT8 ReservedMaskPos;
|
---|
69 | UINT8 DirectColorModeInfo;
|
---|
70 |
|
---|
71 | UINT32 LfbAddress;
|
---|
72 | UINT32 OffScreenAddress;
|
---|
73 | UINT16 OffScreenSizeKB;
|
---|
74 |
|
---|
75 | UINT16 BytesPerScanLineLinear;
|
---|
76 | UINT8 NumImagesLessOneBanked;
|
---|
77 | UINT8 NumImagesLessOneLinear;
|
---|
78 | UINT8 RedMaskSizeLinear;
|
---|
79 | UINT8 RedMaskPosLinear;
|
---|
80 | UINT8 GreenMaskSizeLinear;
|
---|
81 | UINT8 GreenMaskPosLinear;
|
---|
82 | UINT8 BlueMaskSizeLinear;
|
---|
83 | UINT8 BlueMaskPosLinear;
|
---|
84 | UINT8 ReservedMaskSizeLinear;
|
---|
85 | UINT8 ReservedMaskPosLinear;
|
---|
86 | UINT32 MaxPixelClockHz;
|
---|
87 | UINT8 Reserved[190];
|
---|
88 | } VBE_MODE_INFO;
|
---|
89 |
|
---|
90 | typedef struct {
|
---|
91 | UINT16 ModeAttr;
|
---|
92 | UINT8 WindowAAttr;
|
---|
93 | UINT8 WindowBAttr;
|
---|
94 | UINT16 WindowGranularityKB;
|
---|
95 | UINT16 WindowSizeKB;
|
---|
96 | UINT16 WindowAStartSegment;
|
---|
97 | UINT16 WindowBStartSegment;
|
---|
98 | UINT32 WindowPositioningAddress;
|
---|
99 | UINT16 BytesPerScanLine;
|
---|
100 |
|
---|
101 | UINT16 Width;
|
---|
102 | UINT16 Height;
|
---|
103 | UINT8 CharCellWidth;
|
---|
104 | UINT8 CharCellHeight;
|
---|
105 | UINT8 NumPlanes;
|
---|
106 | UINT8 BitsPerPixel;
|
---|
107 | UINT8 NumBanks;
|
---|
108 | UINT8 MemoryModel;
|
---|
109 | UINT8 BankSizeKB;
|
---|
110 | UINT8 NumImagePagesLessOne;
|
---|
111 | UINT8 Vbe3;
|
---|
112 |
|
---|
113 | UINT8 RedMaskSize;
|
---|
114 | UINT8 RedMaskPos;
|
---|
115 | UINT8 GreenMaskSize;
|
---|
116 | UINT8 GreenMaskPos;
|
---|
117 | UINT8 BlueMaskSize;
|
---|
118 | UINT8 BlueMaskPos;
|
---|
119 | UINT8 ReservedMaskSize;
|
---|
120 | UINT8 ReservedMaskPos;
|
---|
121 | UINT8 DirectColorModeInfo;
|
---|
122 |
|
---|
123 | UINT32 LfbAddress;
|
---|
124 | UINT32 OffScreenAddress;
|
---|
125 | UINT16 OffScreenSizeKB;
|
---|
126 | } VBE2_MODE_INFO;
|
---|
127 | #pragma pack ()
|
---|
128 |
|
---|
129 | #endif
|
---|