278 lines
12 KiB
C
278 lines
12 KiB
C
|
/**************************************************************************\
|
||
|
|
||
|
$Header:$
|
||
|
|
||
|
$Log:$
|
||
|
|
||
|
\**************************************************************************/
|
||
|
|
||
|
#include "switches.h"
|
||
|
|
||
|
#ifdef WINDOWS_NT
|
||
|
// Not to be paged out
|
||
|
//#if defined(ALLOC_PRAGMA)
|
||
|
// #pragma data_seg("PAGE")
|
||
|
//#endif
|
||
|
#endif /* #ifdef WINDOWS_NT */
|
||
|
|
||
|
typedef struct {unsigned short r, g, b;} DacReg;
|
||
|
|
||
|
DacReg vgaDac[] = { /* {r, g, b} */
|
||
|
{0x00, 0x00, 0x00}, /* index 00 */
|
||
|
{0x00, 0x00, 0x2a}, /* index 01 */
|
||
|
{0x00, 0x2a, 0x00}, /* index 02 */
|
||
|
{0x00, 0x2a, 0x2a}, /* index 03 */
|
||
|
{0x2a, 0x00, 0x00}, /* index 04 */
|
||
|
{0x2a, 0x00, 0x2a}, /* index 05 */
|
||
|
{0x2a, 0x2a, 0x00}, /* index 06 */
|
||
|
{0x2a, 0x2a, 0x2a}, /* index 07 */
|
||
|
{0x00, 0x00, 0x15}, /* index 08 */
|
||
|
{0x00, 0x00, 0x3f}, /* index 09 */
|
||
|
{0x00, 0x2a, 0x15}, /* index 0a */
|
||
|
{0x00, 0x2a, 0x3f}, /* index 0b */
|
||
|
{0x2a, 0x00, 0x15}, /* index 0c */
|
||
|
{0x2a, 0x00, 0x3f}, /* index 0d */
|
||
|
{0x2a, 0x2a, 0x15}, /* index 0e */
|
||
|
{0x2a, 0x2a, 0x3f}, /* index 0f */
|
||
|
{0x00, 0x15, 0x00}, /* index 10 */
|
||
|
{0x00, 0x15, 0x2a}, /* index 11 */
|
||
|
{0x00, 0x3f, 0x00}, /* index 12 */
|
||
|
{0x00, 0x3f, 0x2a}, /* index 13 */
|
||
|
{0x2a, 0x15, 0x00}, /* index 14 */
|
||
|
{0x2a, 0x15, 0x2a}, /* index 15 */
|
||
|
{0x2a, 0x3f, 0x00}, /* index 16 */
|
||
|
{0x2a, 0x3f, 0x2a}, /* index 17 */
|
||
|
{0x00, 0x15, 0x15}, /* index 18 */
|
||
|
{0x00, 0x15, 0x3f}, /* index 19 */
|
||
|
{0x00, 0x3f, 0x15}, /* index 1a */
|
||
|
{0x00, 0x3f, 0x3f}, /* index 1b */
|
||
|
{0x2a, 0x15, 0x15}, /* index 1c */
|
||
|
{0x2a, 0x15, 0x3f}, /* index 1d */
|
||
|
{0x2a, 0x3f, 0x15}, /* index 1e */
|
||
|
{0x2a, 0x3f, 0x3f}, /* index 1f */
|
||
|
{0x15, 0x00, 0x00}, /* index 20 */
|
||
|
{0x15, 0x00, 0x2a}, /* index 21 */
|
||
|
{0x15, 0x2a, 0x00}, /* index 22 */
|
||
|
{0x15, 0x2a, 0x2a}, /* index 23 */
|
||
|
{0x3f, 0x00, 0x00}, /* index 24 */
|
||
|
{0x3f, 0x00, 0x2a}, /* index 25 */
|
||
|
{0x3f, 0x2a, 0x00}, /* index 26 */
|
||
|
{0x3f, 0x2a, 0x2a}, /* index 27 */
|
||
|
{0x15, 0x00, 0x15}, /* index 28 */
|
||
|
{0x15, 0x00, 0x3f}, /* index 29 */
|
||
|
{0x15, 0x2a, 0x15}, /* index 2a */
|
||
|
{0x15, 0x2a, 0x3f}, /* index 2b */
|
||
|
{0x3f, 0x00, 0x15}, /* index 2c */
|
||
|
{0x3f, 0x00, 0x3f}, /* index 2d */
|
||
|
{0x3f, 0x2a, 0x15}, /* index 2e */
|
||
|
{0x3f, 0x2a, 0x3f}, /* index 2f */
|
||
|
{0x15, 0x15, 0x00}, /* index 30 */
|
||
|
{0x15, 0x15, 0x2a}, /* index 31 */
|
||
|
{0x15, 0x3f, 0x00}, /* index 32 */
|
||
|
{0x15, 0x3f, 0x2a}, /* index 33 */
|
||
|
{0x3f, 0x15, 0x00}, /* index 34 */
|
||
|
{0x3f, 0x15, 0x2a}, /* index 35 */
|
||
|
{0x3f, 0x3f, 0x00}, /* index 36 */
|
||
|
{0x3f, 0x3f, 0x2a}, /* index 37 */
|
||
|
{0x15, 0x15, 0x15}, /* index 38 */
|
||
|
{0x15, 0x15, 0x3f}, /* index 39 */
|
||
|
{0x15, 0x3f, 0x15}, /* index 3a */
|
||
|
{0x15, 0x3f, 0x3f}, /* index 3b */
|
||
|
{0x3f, 0x15, 0x15}, /* index 3c */
|
||
|
{0x3f, 0x15, 0x3f}, /* index 3d */
|
||
|
{0x3f, 0x3f, 0x15}, /* index 3e */
|
||
|
{0x3f, 0x3f, 0x3f}, /* index 3f */
|
||
|
{0x00, 0x00, 0x00}, /* index 40 */
|
||
|
{0x00, 0x00, 0x00}, /* index 41 */
|
||
|
{0x00, 0x00, 0x00}, /* index 42 */
|
||
|
{0x00, 0x00, 0x00}, /* index 43 */
|
||
|
{0x00, 0x00, 0x00}, /* index 44 */
|
||
|
{0x00, 0x00, 0x00}, /* index 45 */
|
||
|
{0x00, 0x00, 0x00}, /* index 46 */
|
||
|
{0x00, 0x00, 0x00}, /* index 47 */
|
||
|
{0x00, 0x00, 0x00}, /* index 48 */
|
||
|
{0x00, 0x00, 0x00}, /* index 49 */
|
||
|
{0x00, 0x00, 0x00}, /* index 4a */
|
||
|
{0x00, 0x00, 0x00}, /* index 4b */
|
||
|
{0x00, 0x00, 0x00}, /* index 4c */
|
||
|
{0x00, 0x00, 0x00}, /* index 4d */
|
||
|
{0x00, 0x00, 0x00}, /* index 4e */
|
||
|
{0x00, 0x00, 0x00}, /* index 4f */
|
||
|
{0x00, 0x00, 0x00}, /* index 50 */
|
||
|
{0x00, 0x00, 0x00}, /* index 51 */
|
||
|
{0x00, 0x00, 0x00}, /* index 52 */
|
||
|
{0x00, 0x00, 0x00}, /* index 53 */
|
||
|
{0x00, 0x00, 0x00}, /* index 54 */
|
||
|
{0x00, 0x00, 0x00}, /* index 55 */
|
||
|
{0x00, 0x00, 0x00}, /* index 56 */
|
||
|
{0x00, 0x00, 0x00}, /* index 57 */
|
||
|
{0x00, 0x00, 0x00}, /* index 58 */
|
||
|
{0x00, 0x00, 0x00}, /* index 59 */
|
||
|
{0x00, 0x00, 0x00}, /* index 5a */
|
||
|
{0x00, 0x00, 0x00}, /* index 5b */
|
||
|
{0x00, 0x00, 0x00}, /* index 5c */
|
||
|
{0x00, 0x00, 0x00}, /* index 5d */
|
||
|
{0x00, 0x00, 0x00}, /* index 5e */
|
||
|
{0x00, 0x00, 0x00}, /* index 5f */
|
||
|
{0x00, 0x00, 0x00}, /* index 60 */
|
||
|
{0x00, 0x00, 0x00}, /* index 61 */
|
||
|
{0x00, 0x00, 0x00}, /* index 62 */
|
||
|
{0x00, 0x00, 0x00}, /* index 63 */
|
||
|
{0x00, 0x00, 0x00}, /* index 64 */
|
||
|
{0x00, 0x00, 0x00}, /* index 65 */
|
||
|
{0x00, 0x00, 0x00}, /* index 66 */
|
||
|
{0x00, 0x00, 0x00}, /* index 67 */
|
||
|
{0x00, 0x00, 0x00}, /* index 68 */
|
||
|
{0x00, 0x00, 0x00}, /* index 69 */
|
||
|
{0x00, 0x00, 0x00}, /* index 6a */
|
||
|
{0x00, 0x00, 0x00}, /* index 6b */
|
||
|
{0x00, 0x00, 0x00}, /* index 6c */
|
||
|
{0x00, 0x00, 0x00}, /* index 6d */
|
||
|
{0x00, 0x00, 0x00}, /* index 6e */
|
||
|
{0x00, 0x00, 0x00}, /* index 6f */
|
||
|
{0x00, 0x00, 0x00}, /* index 70 */
|
||
|
{0x00, 0x00, 0x00}, /* index 71 */
|
||
|
{0x00, 0x00, 0x00}, /* index 72 */
|
||
|
{0x00, 0x00, 0x00}, /* index 73 */
|
||
|
{0x00, 0x00, 0x00}, /* index 74 */
|
||
|
{0x00, 0x00, 0x00}, /* index 75 */
|
||
|
{0x00, 0x00, 0x00}, /* index 76 */
|
||
|
{0x00, 0x00, 0x00}, /* index 77 */
|
||
|
{0x00, 0x00, 0x00}, /* index 78 */
|
||
|
{0x00, 0x00, 0x00}, /* index 79 */
|
||
|
{0x00, 0x00, 0x00}, /* index 7a */
|
||
|
{0x00, 0x00, 0x00}, /* index 7b */
|
||
|
{0x00, 0x00, 0x00}, /* index 7c */
|
||
|
{0x00, 0x00, 0x00}, /* index 7d */
|
||
|
{0x00, 0x00, 0x00}, /* index 7e */
|
||
|
{0x00, 0x00, 0x00}, /* index 7f */
|
||
|
{0x00, 0x00, 0x00}, /* index 80 */
|
||
|
{0x00, 0x00, 0x00}, /* index 81 */
|
||
|
{0x00, 0x00, 0x00}, /* index 82 */
|
||
|
{0x00, 0x00, 0x00}, /* index 83 */
|
||
|
{0x00, 0x00, 0x00}, /* index 84 */
|
||
|
{0x00, 0x00, 0x00}, /* index 85 */
|
||
|
{0x00, 0x00, 0x00}, /* index 86 */
|
||
|
{0x00, 0x00, 0x00}, /* index 87 */
|
||
|
{0x00, 0x00, 0x00}, /* index 88 */
|
||
|
{0x00, 0x00, 0x00}, /* index 89 */
|
||
|
{0x00, 0x00, 0x00}, /* index 8a */
|
||
|
{0x00, 0x00, 0x00}, /* index 8b */
|
||
|
{0x00, 0x00, 0x00}, /* index 8c */
|
||
|
{0x00, 0x00, 0x00}, /* index 8d */
|
||
|
{0x00, 0x00, 0x00}, /* index 8e */
|
||
|
{0x00, 0x00, 0x00}, /* index 8f */
|
||
|
{0x00, 0x00, 0x00}, /* index 90 */
|
||
|
{0x00, 0x00, 0x00}, /* index 91 */
|
||
|
{0x00, 0x00, 0x00}, /* index 92 */
|
||
|
{0x00, 0x00, 0x00}, /* index 93 */
|
||
|
{0x00, 0x00, 0x00}, /* index 94 */
|
||
|
{0x00, 0x00, 0x00}, /* index 95 */
|
||
|
{0x00, 0x00, 0x00}, /* index 96 */
|
||
|
{0x00, 0x00, 0x00}, /* index 97 */
|
||
|
{0x00, 0x00, 0x00}, /* index 98 */
|
||
|
{0x00, 0x00, 0x00}, /* index 99 */
|
||
|
{0x00, 0x00, 0x00}, /* index 9a */
|
||
|
{0x00, 0x00, 0x00}, /* index 9b */
|
||
|
{0x00, 0x00, 0x00}, /* index 9c */
|
||
|
{0x00, 0x00, 0x00}, /* index 9d */
|
||
|
{0x00, 0x00, 0x00}, /* index 9e */
|
||
|
{0x00, 0x00, 0x00}, /* index 9f */
|
||
|
{0x00, 0x00, 0x00}, /* index a0 */
|
||
|
{0x00, 0x00, 0x00}, /* index a1 */
|
||
|
{0x00, 0x00, 0x00}, /* index a2 */
|
||
|
{0x00, 0x00, 0x00}, /* index a3 */
|
||
|
{0x00, 0x00, 0x00}, /* index a4 */
|
||
|
{0x00, 0x00, 0x00}, /* index a5 */
|
||
|
{0x00, 0x00, 0x00}, /* index a6 */
|
||
|
{0x00, 0x00, 0x00}, /* index a7 */
|
||
|
{0x00, 0x00, 0x00}, /* index a8 */
|
||
|
{0x00, 0x00, 0x00}, /* index a9 */
|
||
|
{0x00, 0x00, 0x00}, /* index aa */
|
||
|
{0x00, 0x00, 0x00}, /* index ab */
|
||
|
{0x00, 0x00, 0x00}, /* index ac */
|
||
|
{0x00, 0x00, 0x00}, /* index ad */
|
||
|
{0x00, 0x00, 0x00}, /* index ae */
|
||
|
{0x00, 0x00, 0x00}, /* index af */
|
||
|
{0x00, 0x00, 0x00}, /* index b0 */
|
||
|
{0x00, 0x00, 0x00}, /* index b1 */
|
||
|
{0x00, 0x00, 0x00}, /* index b2 */
|
||
|
{0x00, 0x00, 0x00}, /* index b3 */
|
||
|
{0x00, 0x00, 0x00}, /* index b4 */
|
||
|
{0x00, 0x00, 0x00}, /* index b5 */
|
||
|
{0x00, 0x00, 0x00}, /* index b6 */
|
||
|
{0x00, 0x00, 0x00}, /* index b7 */
|
||
|
{0x00, 0x00, 0x00}, /* index b8 */
|
||
|
{0x00, 0x00, 0x00}, /* index b9 */
|
||
|
{0x00, 0x00, 0x00}, /* index ba */
|
||
|
{0x00, 0x00, 0x00}, /* index bb */
|
||
|
{0x00, 0x00, 0x00}, /* index bc */
|
||
|
{0x00, 0x00, 0x00}, /* index bd */
|
||
|
{0x00, 0x00, 0x00}, /* index be */
|
||
|
{0x00, 0x00, 0x00}, /* index bf */
|
||
|
{0x00, 0x00, 0x00}, /* index c0 */
|
||
|
{0x00, 0x00, 0x00}, /* index c1 */
|
||
|
{0x00, 0x00, 0x00}, /* index c2 */
|
||
|
{0x00, 0x00, 0x00}, /* index c3 */
|
||
|
{0x00, 0x00, 0x00}, /* index c4 */
|
||
|
{0x00, 0x00, 0x00}, /* index c5 */
|
||
|
{0x00, 0x00, 0x00}, /* index c6 */
|
||
|
{0x00, 0x00, 0x00}, /* index c7 */
|
||
|
{0x00, 0x00, 0x00}, /* index c8 */
|
||
|
{0x00, 0x00, 0x00}, /* index c9 */
|
||
|
{0x00, 0x00, 0x00}, /* index ca */
|
||
|
{0x00, 0x00, 0x00}, /* index cb */
|
||
|
{0x00, 0x00, 0x00}, /* index cc */
|
||
|
{0x00, 0x00, 0x00}, /* index cd */
|
||
|
{0x00, 0x00, 0x00}, /* index ce */
|
||
|
{0x00, 0x00, 0x00}, /* index cf */
|
||
|
{0x00, 0x00, 0x00}, /* index d0 */
|
||
|
{0x00, 0x00, 0x00}, /* index d1 */
|
||
|
{0x00, 0x00, 0x00}, /* index d2 */
|
||
|
{0x00, 0x00, 0x00}, /* index d3 */
|
||
|
{0x00, 0x00, 0x00}, /* index d4 */
|
||
|
{0x00, 0x00, 0x00}, /* index d5 */
|
||
|
{0x00, 0x00, 0x00}, /* index d6 */
|
||
|
{0x00, 0x00, 0x00}, /* index d7 */
|
||
|
{0x00, 0x00, 0x00}, /* index d8 */
|
||
|
{0x00, 0x00, 0x00}, /* index d9 */
|
||
|
{0x00, 0x00, 0x00}, /* index da */
|
||
|
{0x00, 0x00, 0x00}, /* index db */
|
||
|
{0x00, 0x00, 0x00}, /* index dc */
|
||
|
{0x00, 0x00, 0x00}, /* index dd */
|
||
|
{0x00, 0x00, 0x00}, /* index de */
|
||
|
{0x00, 0x00, 0x00}, /* index df */
|
||
|
{0x00, 0x00, 0x00}, /* index e0 */
|
||
|
{0x00, 0x00, 0x00}, /* index e1 */
|
||
|
{0x00, 0x00, 0x00}, /* index e2 */
|
||
|
{0x00, 0x00, 0x00}, /* index e3 */
|
||
|
{0x00, 0x00, 0x00}, /* index e4 */
|
||
|
{0x00, 0x00, 0x00}, /* index e5 */
|
||
|
{0x00, 0x00, 0x00}, /* index e6 */
|
||
|
{0x00, 0x00, 0x00}, /* index e7 */
|
||
|
{0x00, 0x00, 0x00}, /* index e8 */
|
||
|
{0x00, 0x00, 0x00}, /* index e9 */
|
||
|
{0x00, 0x00, 0x00}, /* index ea */
|
||
|
{0x00, 0x00, 0x00}, /* index eb */
|
||
|
{0x00, 0x00, 0x00}, /* index ec */
|
||
|
{0x00, 0x00, 0x00}, /* index ed */
|
||
|
{0x00, 0x00, 0x00}, /* index ee */
|
||
|
{0x00, 0x00, 0x00}, /* index ef */
|
||
|
{0x00, 0x00, 0x00}, /* index f0 */
|
||
|
{0x00, 0x00, 0x00}, /* index f1 */
|
||
|
{0x00, 0x00, 0x00}, /* index f2 */
|
||
|
{0x00, 0x00, 0x00}, /* index f3 */
|
||
|
{0x00, 0x00, 0x00}, /* index f4 */
|
||
|
{0x00, 0x00, 0x00}, /* index f5 */
|
||
|
{0x00, 0x00, 0x00}, /* index f6 */
|
||
|
{0x00, 0x00, 0x00}, /* index f7 */
|
||
|
{0x00, 0x00, 0x00}, /* index f8 */
|
||
|
{0x00, 0x00, 0x00}, /* index f9 */
|
||
|
{0x00, 0x00, 0x00}, /* index fa */
|
||
|
{0x00, 0x00, 0x00}, /* index fb */
|
||
|
{0x00, 0x00, 0x00}, /* index fc */
|
||
|
{0x00, 0x00, 0x00}, /* index fd */
|
||
|
{0x00, 0x00, 0x00}, /* index fe */
|
||
|
{0x00, 0x00, 0x00} /* index ff */
|
||
|
};
|