eeaddd56766ee31f8c83924cd70d177ba73de652
[tpg/acess2.git] / Modules / Display / VESA / common.h
1 /**
2  */
3 #ifndef _COMMON_H_
4 #define _COMMON_H_
5
6 // === TYPES ===
7 typedef struct sFarPtr
8 {
9         Uint16  ofs;
10         Uint16  seg;
11 }       tFarPtr;
12
13 typedef struct sVesa_Mode
14 {
15         Uint16  code;
16         Uint16  width, height;
17         Uint16  pitch, bpp;
18         Uint16  flags;
19         Uint32  fbSize;
20         Uint32  framebuffer;
21 }       tVesa_Mode;
22
23 typedef struct sVesa_CallModeInfo
24 {
25         Uint16  attributes;
26         Uint8   winA,winB;
27         Uint16  granularity;
28         Uint16  winsize;
29         Uint16  segmentA, segmentB;
30         tFarPtr realFctPtr;
31         Uint16  pitch;  // Bytes per scanline
32
33         Uint16  Xres, Yres;
34         Uint8   Wchar, Ychar, planes, bpp, banks;
35         Uint8   memory_model, bank_size, image_pages;
36         Uint8   reserved0;
37
38         Uint8   red_mask, red_position;
39         Uint8   green_mask, green_position;
40         Uint8   blue_mask, blue_position;
41         Uint8   rsv_mask, rsv_position;
42         Uint8   directcolor_attributes;
43
44         Uint32  physbase;  // Your LFB address ;)
45         Uint32  reserved1;
46         Sint16  reserved2;
47 }       tVesa_CallModeInfo;
48
49 typedef struct sVesa_CallInfo
50 {
51    char         signature[4];           // == "VESA"
52    Uint16       Version;        // == 0x0300 for Vesa 3.0
53    tFarPtr      OEMString;      // isa vbeFarPtr
54    Uint8        Capabilities[4];        
55    tFarPtr      VideoModes;     // isa vbeParPtr
56    Uint16       TotalMemory;    // as # of 64KB blocks
57 }       tVesa_CallInfo;
58
59 #endif

UCC git Repository :: git.ucc.asn.au