home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / ddkx86v2.zip / DDKX86 / DBCSDD / SRC_DBCS / VDHV / VDHDATA.H < prev    next >
C/C++ Source or Header  |  1995-04-14  |  19KB  |  364 lines

  1. /*DDK*************************************************************************/
  2. /*                                                                           */
  3. /* COPYRIGHT (C) Microsoft Corporation, 1989                                 */
  4. /* COPYRIGHT    Copyright (C) 1995 IBM Corporation                           */
  5. /*                                                                           */
  6. /*    The following IBM OS/2 WARP source code is provided to you solely for  */
  7. /*    the purpose of assisting you in your development of OS/2 WARP device   */
  8. /*    drivers. You may use this code in accordance with the IBM License      */
  9. /*    Agreement provided in the IBM Device Driver Source Kit for OS/2. This  */
  10. /*    Copyright statement may not be removed.                                */
  11. /*                                                                           */
  12. /*****************************************************************************/
  13. /**************************************************************************
  14.  *
  15.  * SOURCE FILE NAME = VDHDATA.H
  16.  *
  17.  * DESCRIPTIVE NAME = Video Device Handler data include file
  18.  *
  19.  *
  20.  * VERSION = V2.0
  21.  *
  22.  * DATE
  23.  *
  24.  * DESCRIPTION
  25.  *
  26.  * FUNCTIONS    NONE
  27.  *
  28.  * NOTES
  29.  *
  30.  *
  31.  * STRUCTURES
  32.  *
  33.  * EXTERNAL REFERENCES
  34.  *
  35.  * EXTERNAL FUNCTIONS
  36.  *
  37. */
  38.  
  39. /*----------------------------------------------------------------------------*/
  40. /* Global variables - data shared by more than one VDH routine                */
  41. /*----------------------------------------------------------------------------*/
  42. USHORT HugeShift = 0;   /* Amount added to a huge selector to get to the next */
  43. USHORT DeviceDriver = 0;/* version number                                     */
  44. UCHAR FIRST_ENTRY = TRUE; /* Flag to force only one device initialization     */
  45. UCHAR FIRST_INIT = TRUE; /* Flag to force only one INIT device initialization */
  46. UCHAR FIRST_RETCONFIG = TRUE; /* Flag to First RetConfigInfo entry.     J-KKJ */
  47. USHORT IStart = 0;       /* Mode table starting point (memory-size dependent) */
  48. UCHAR READABLE = 0;      /* Flag to determine if hardware is write-only */
  49. USHORT ConfigFlag = 0;
  50. ULONG PartialSaveSize=0;/* Room required to save entire PVB in the popup mode */
  51. UCHAR DefaultAttribute[] = {0x07,0x0,0x0};/* default attribute used by WrtTTY */
  52. CLUTDATA far *LCLUT = 0 ;                                              /*@S40f*/
  53. USHORT CodePageZero = 437;   // VGA ROM Code Page                     J-KK1024
  54. SEL   CommonSelector = 0;    /* Common Selector to Xvio               J-KK0929*/
  55.  
  56. VIDEOHARDWARE VideoHardware = {0};  /* installed video hardware */      /*@T39*/
  57. #ifdef  J_INSTALL                                                       //J-TS00V
  58. VIDEOHARDWAREJ VideoHardwareJ = {0};  /* installed video hardware */    //J-TS00V
  59. #endif  //J_INSTALL                                                     //J-TS00V
  60.  
  61. USHORT InitPointerDone = FALSE; /* pointer initialization done flag */  //J-TS111692
  62. DOSFSRSEM SemAccessAPA = {0};   /* APA exclusive access semaphore */    //J-TS011792
  63.  
  64. ENVIRONMENT Env1 = {0}; /* Popup environment */                   /*@T42,@T42f*/
  65. ENVIRONMENT Env2 = {0}; /* Harderr environment */                 /*@T42,@T42f*/
  66.  
  67. UCHAR HarderrFlag = 0 ; // Hard Error Flag                              @KK0622
  68.  
  69. //@2KK0531 USHORT CodePageTable[MAX_CODEPAGES];              /* Code Page Table  J-KK1002*/
  70. USHORT CodePageTable[MAX_CODEPAGES] = {0};     /* Code Page Table  @2KK0531*/
  71.  
  72. USHORT (APIENTRY *ChainedCallVectorTable[MaxFn])() = {0};            /* @T24 */
  73.  
  74. USHORT VGA_PRESENT = 0;  /* TRUE if VGA VDH has been installed */
  75. VDHCONFIGINFO VGAConfigData = {0};
  76.  
  77. extern USHORT hScreenDD;     /* Handle to screen device driver ( for DosDevIOCtl ) */
  78.  
  79. // OEM Flags:
  80. //      This word contains flags used to remember that an OEM video
  81. //      adapter has been detected.  This may be used to control the
  82. //      programming of features unique to a particular vendor's
  83. //      implementation of one of the OS/2 supported video adapters.
  84.  
  85. USHORT  OEMFlags        = 0x0000;
  86. USHORT  SVGAPresent     = FALSE;                // @drw
  87.  
  88. /*----------------------------------------------------------------------------*/
  89. /* Table of VDH entry points                                                  */
  90. /*                                                                            */
  91. /* Device chaining is not implemented in these video device handlers.  If the */
  92. /* VDH supports the VDH function, DevEnable will over-write the current       */
  93. /* entry in the call vector table.  If the VDH does not support the VDH       */
  94. /* function, the call vector table entry will not be touched.                 */
  95. /*----------------------------------------------------------------------------*/
  96. #ifdef  J_INSTALL                                                       //J-TS00
  97. static USHORT far * far VDHEntryPoint[] = {
  98.  
  99.                              (USHORT far *)BufferUpdate,        /* 256 */
  100.                              (USHORT far *)InitEnv,             /* 257 */
  101.                              (USHORT far *)SaveEnv,             /* 258 */
  102.                              (USHORT far *)RestoreEnv,          /* 259 */
  103.                              (USHORT far *)RetConfigInfo,       /* 260 */
  104. /* Get DBCS Display Info */  (USHORT far *)GetDBCSInfo,         /* 261  @P1 */
  105.                              (USHORT far *)UNSUPPORTED_FUNCTION,/* 262 */
  106.                              (USHORT far *)UNSUPPORTED_FUNCTION,/* 263 */
  107.                              (USHORT far *)GetCursorInfo,       /* 264 */
  108.                              (USHORT far *)SetCursorInfo,       /* 265 */
  109.                              (USHORT far *)UNSUPPORTED_FUNCTION,/* 266 */
  110.                              (USHORT far *)UNSUPPORTED_FUNCTION,/* 267 */
  111.                              (USHORT far *)GetMode,             /* 268 */
  112.                              (USHORT far *)SetMode,             /* 269 */
  113.                              (USHORT far *)UNSUPPORTED_FUNCTION,/* 270 */
  114.                              (USHORT far *)UNSUPPORTED_FUNCTION,/* 271 */
  115.                              (USHORT far *)UNSUPPORTED_FUNCTION,/* 272 */
  116.                              (USHORT far *)UNSUPPORTED_FUNCTION,/* 273 */
  117.                              (USHORT far *)GetVariableInfo,     /* 274 */
  118.                              (USHORT far *)SetVariableInfo,     /* 275 */
  119.                              (USHORT far *)UNSUPPORTED_FUNCTION,/* 276  @P1 */
  120.                              (USHORT far *)UNSUPPORTED_FUNCTION,/* 277 */ //J-TS00
  121.                              (USHORT far *)UNSUPPORTED_FUNCTION,/* 278  @P1 */
  122. /* Get LVB size info     */  (USHORT far *)GetLVBInfo};         /* 279  @P1 */
  123. #else   //J_INSTALL                                                     //J-TS00
  124. static USHORT far * far VDHEntryPoint[] = {
  125.  
  126.                              (USHORT far *)BufferUpdate,        /* 256 */
  127.                              (USHORT far *)InitEnv,             /* 257 */
  128.                              (USHORT far *)SaveEnv,             /* 258 */
  129.                              (USHORT far *)RestoreEnv,          /* 259 */
  130.                              (USHORT far *)RetConfigInfo,       /* 260 */
  131. /* Get DBCS Display Info */  (USHORT far *)GetDBCSInfo,         /* 261  @P1 */
  132.                              (USHORT far *)GetColorLookup,      /* 262 */
  133.                              (USHORT far *)SetColorLookup,      /* 263 */
  134.                              (USHORT far *)GetCursorInfo,       /* 264 */
  135.                              (USHORT far *)SetCursorInfo,       /* 265 */
  136.                              (USHORT far *)GetCurrentFont,      /* 266 */
  137.                              (USHORT far *)SetCurrentFont,      /* 267 */
  138.                              (USHORT far *)GetMode,             /* 268 */
  139.                              (USHORT far *)SetMode,             /* 269 */
  140.                              (USHORT far *)GetPaletteReg,       /* 270 */
  141.                              (USHORT far *)SetPaletteReg,       /* 271 */
  142.                              (USHORT far *)GetPhysBuf,          /* 272 */
  143.                              (USHORT far *)FreePhysBuf,         /* 273 */
  144.                              (USHORT far *)GetVariableInfo,     /* 274 */
  145.                              (USHORT far *)SetVariableInfo,     /* 275 */
  146.                              (USHORT far *)CloseEnv,            /* 276  @P1 */ //J-TS00
  147.                              (USHORT far *)PrintScreen,         /* 277 */ //J-TS00
  148.                              (USHORT far *)UNSUPPORTED_FUNCTION,/* 278  @P1 */
  149. /* Get LVB size info     */  (USHORT far *)GetLVBInfo};         /* 279  @P1 */
  150. #endif  //J_INSTALL                                                     //J-TS00
  151.  
  152. //-----------------------------------------------------------------------------
  153. // Video Mode Table
  154. //
  155. // typedef struct {
  156. //           USHORT cb;              /* VioGetMode structure              */
  157. //           UCHAR  fbType;
  158. //           UCHAR  color;
  159. //           USHORT col;
  160. //           USHORT row;
  161. //           USHORT hres;
  162. //           USHORT vres;
  163. //           UCHAR  fmt_ID;
  164. //           UCHAR  attrib;
  165. //
  166. //           USHORT Format_Index;
  167. //           USHORT HW_Index;
  168. //           } VIDEOMODE;
  169. //-----------------------------------------------------------------------------
  170.  
  171.     VIDEOMODE Modes[] = {
  172.  
  173. //  0 CO80 3+ Emulation Mode
  174.         { 14, 1, 4, 80, 25,  720, 400,    0, 1, MemMap_ATLAS, ATLASUS_Format, HW_DBCS_VGA },
  175.  
  176. //  1 CO80 3* Emulation Mode
  177.         { 14, 1, 4, 80, 25,  640, 350,    0, 1, MemMap_ATLAS, ATLASUS_Format, HW_DBCS_VGA },
  178.  
  179. //  2 CO80 3  Emualtion Mode
  180.         { 14, 1, 4, 80, 25,  640, 200,    0, 1, MemMap_ATLAS, ATLASUS_Format, HW_DBCS_VGA },
  181.  
  182. //  3 MONO 7+ Emulation Mode
  183.         { 14, 0, 0, 80, 25,  720, 400,    0, 1, MemMap_ATLAS, ATLASUS_Format, HW_DBCS_VGA },
  184.  
  185. //  4 MONO 7  Emulation Mode
  186.         { 14, 0, 0, 80, 25,  720, 350,    0, 1, MemMap_ATLAS, ATLASUS_Format, HW_DBCS_VGA },
  187.  
  188. //  5 ATLAS   Common    Mode
  189.         { 14, 1, 4, 80, 25, 1040, 725, 0x70, 3, MemMap_ATLAS, COMMON_Format,  HW_ATLAS    },
  190.  
  191. //  6 ATLAS Color 82x25 Mode
  192.         { 14, 1, 4, 82, 25, 1066, 725,    0, 3, MemMap_ATLAS, ATLAS3_Format,  HW_ATLAS3_C },
  193.  
  194. //  7 ATLAS Mono  82x25 Mode
  195.         { 14, 1, 1, 82, 25, 1066, 725,    0, 3, MemMap_ATLAS, ATLAS3_Format,  HW_ATLAS3_M },
  196.  
  197. //  8 EPOCH   Mono      Mode
  198.         { 14, 1, 1, 80, 25, 1040, 725,    1, 1, MemMap_ATLAS, EPOCH_Format,   HW_EPOCH_M  },
  199.  
  200. //  9 EPOCH   Mono      Mode
  201.         { 14, 1, 1, 80, 24, 1040, 696,    1, 1, MemMap_ATLAS, EPOCH_Format,   HW_EPOCH_M  },
  202.  
  203. // 10 EPOCH   Mono      Mode
  204.         { 14, 1, 1, 80, 24, 1040, 725,    1, 1, MemMap_ATLAS, EPOCH_Format,   HW_EPOCH_M  },
  205.  
  206. // 11 EPOCH   Color     Mode
  207.         { 14, 1, 4, 80, 25, 1040, 725,    1, 1, MemMap_ATLAS, EPOCH_Format,   HW_EPOCH_C  },
  208.  
  209. // 12 EPOCH   Color     Mode
  210.         { 14, 1, 4, 80, 24, 1040, 696,    1, 1, MemMap_ATLAS, EPOCH_Format,   HW_EPOCH_C  },
  211.  
  212. // 13 EPOCH   Color     Mode
  213.         { 14, 1, 4, 80, 24, 1040, 725,    1, 1, MemMap_ATLAS, EPOCH_Format,   HW_EPOCH_C  }
  214.     };
  215.  
  216. //-----------------------------------------------------------------------------
  217. //  Hardware Defaults Setting Values Table
  218. //
  219. // typedef struct {
  220. //             UCHAR Palettes[0x0F+1];
  221. //             UCHAR GridColor;
  222. //             UCHAR CursorColor;
  223. //             UCHAR CursorControl;
  224. //             UCHAR CursorStart;
  225. //             UCHAR CursorEnd;
  226. //             UCHAR CursorLocHigh;
  227. //             UCHAR CursorLocLow;
  228. //             UCHAR CursorWidth;
  229. //             REGCMD ModeRegs[MAX_MODE_CMDS+1];   /* Register command table */
  230. //           } HW_DEFAULT;
  231. //-----------------------------------------------------------------------------
  232.  
  233.     HW_DEFAULT HW_Default[] = {
  234.  
  235. // ATLAS Color ( 80x26 )  ; 80x26 Color Text For Protect Mode
  236.         {
  237.           0x0F, 0x0F, 0, 26, 27, 0, 0, 1,
  238.           {
  239.             { RegOutput_CMD,  { "\xE3", MiscOutputRegWrite, 0x01 } },
  240.             { Sequencers_CMD, { "\x01\x01\x0F\x00\x06", 0x00, 0x04+1 } },
  241.             { CRTCtlRegs_CMD, { "\x05", 0x11, 0x01 } },
  242.             { CRTCtlRegs_CMD, { "\x5F\x4F\x50\x82\x54\x80\xB\x3E\x0\x40\x0\x0\x0\x0\x0\x0\xEA\x8C\xD3\x40\x0\xE7\x4\xC3\xFF", 0x00, 0x18+1 } },
  243.             { RegOutput_CMD,  { "\xE3", MiscOutputRegWrite, 0x01 } },
  244.             { Attributes_CMD, { "\x0\x1\x2\x3\x4\x5\x14\x7\x38\x39\x3A\x3B\x3C\x3D\x3E\x3F\x01\x0\x0F\x0\x0", 0x00, 0x15 } },
  245.             { Graphics_CMD,   { "\x0\x0\x0\x0\x0\x0\x05\x0F\x0FF", 0x00, 0x09 } },
  246.             { Terminate_CMD }
  247.           }
  248.         },
  249.  
  250. // ATLAS DBCS VGA ( 80x26 )  ; 80x26 Color Text For Protect Mode (VGA emulation)
  251.         {
  252.           0x0F, 0x0F, 0, 14, 15, 0, 0, 1,
  253.           {
  254.             { RegOutput_CMD,  { "\xE3", MiscOutputRegWrite, 0x01 } },
  255.             { Sequencers_CMD, { "\x01\x01\x0F\x00\x06", 0x00, 0x04+1 } },
  256.             { CRTCtlRegs_CMD, { "\x05", 0x11, 0x01 } },
  257.             { CRTCtlRegs_CMD, { "\x5F\x4F\x50\x82\x54\x80\xB\x3E\x0\x40\x0\x0\x0\x0\x0\x0\xEA\x8C\xD3\x40\x0\xE7\x4\xC3\xFF", 0x00, 0x18+1 } },
  258.             { RegOutput_CMD,  { "\xE3", MiscOutputRegWrite, 0x01 } },
  259.             { Attributes_CMD, { "\x0\x1\x2\x3\x4\x5\x14\x7\x38\x39\x3A\x3B\x3C\x3D\x3E\x3F\x01\x0\x0F\x0\x0", 0x00, 0x15 } },
  260.             { Graphics_CMD,   { "\x0\x0\x0\x0\x0\x0\x05\x0F\x0FF", 0x00, 0x09 } },
  261.             { Terminate_CMD }
  262.           }
  263.         },
  264.  
  265. // ATLAS 3bytes Mono ( 82x26 )  ; 82x26 Color Text For Protect Mode
  266.         {
  267.           0x07, 0x02, 0, 26, 27, 0, 0, 1,
  268.           {
  269.             { RegOutput_CMD,  { "\xE3", MiscOutputRegWrite, 0x01 } },
  270.             { Sequencers_CMD, { "\x01\x01\x0F\x00\x06", 0x00, 0x04+1 } },
  271.             { CRTCtlRegs_CMD, { "\x05", 0x11, 0x01 } },
  272.             { CRTCtlRegs_CMD, { "\x5F\x4F\x50\x82\x54\x80\xB\x3E\x0\x40\x0\x0\x0\x0\x0\x0\xEA\x8C\xD3\x40\x0\xE7\x4\xC3\xFF", 0x00, 0x18+1 } },
  273.             { RegOutput_CMD,  { "\xE3", MiscOutputRegWrite, 0x01 } },
  274.             { Attributes_CMD, { "\x0\x9\x12\x1B\x24\x2D\x36\x3F\x38\x39\x3A\x3B\x3C\x3D\x3E\x3F\x01\x0\x0F\x0\x0", 0x00, 0x15 } },
  275.             { Graphics_CMD,   { "\x0\x0\x0\x0\x0\x0\x05\x0F\x0FF", 0x00, 0x09 } },
  276.             { Terminate_CMD }
  277.           }
  278.         },
  279.  
  280. // ATLAS 3bytes Color ( 82x26 ) ; 82x26 Color Text For Protect Mode
  281.         {
  282.           0x07, 0x0F, 0, 26, 27, 0, 0, 1,
  283.           {
  284.             { RegOutput_CMD,  { "\xE3", MiscOutputRegWrite, 0x01 } },
  285.             { Sequencers_CMD, { "\x01\x01\x0F\x00\x06", 0x00, 0x04+1 } },
  286.             { CRTCtlRegs_CMD, { "\x05", 0x11, 0x01 } },
  287.             { CRTCtlRegs_CMD, { "\x5F\x4F\x50\x82\x54\x80\xB\x3E\x0\x40\x0\x0\x0\x0\x0\x0\xEA\x8C\xD3\x40\x0\xE7\x4\xC3\xFF", 0x00, 0x18+1 } },
  288.             { RegOutput_CMD,  { "\xE3", MiscOutputRegWrite, 0x01 } },
  289.             { Attributes_CMD, { "\x0\x9\x12\x1B\x24\x2D\x36\x3F\x38\x39\x3A\x3B\x3C\x3D\x3E\x3F\x01\x0\x0F\x0\x0", 0x00, 0x15 } },
  290.             { Graphics_CMD,   { "\x0\x0\x0\x0\x0\x0\x05\x0F\x0FF", 0x00, 0x09 } },
  291.             { Terminate_CMD }
  292.           }
  293.         },
  294.  
  295. // 80x26 EPOCH Mono Emulation For Protect Mode
  296.         {
  297.           0x0A, 0x0E, 0, 26, 27, 0, 0, 1,
  298.           {
  299.             { RegOutput_CMD,  { "\xE3", MiscOutputRegWrite, 0x01 } },
  300.             { Sequencers_CMD, { "\x01\x01\x0F\x00\x06", 0x00, 0x04+1 } },
  301.             { CRTCtlRegs_CMD, { "\x05", 0x11, 0x01 } },
  302.             { CRTCtlRegs_CMD, { "\x5F\x4F\x50\x82\x54\x80\xB\x3E\x0\x40\x0\x0\x0\x0\x0\x0\xEA\x8C\xD3\x40\x0\xE7\x4\xC3\xFF", 0x00, 0x18+1 } },
  303.             { RegOutput_CMD,  { "\xE3", MiscOutputRegWrite, 0x01 } },
  304.             { Attributes_CMD, { "\x0\x1\x2\x3\x4\x5\x36\x7\x0\x39\x3A\x3B\x3C\x3D\x3A\x3F\x01\x0\x0F\x0\x0", 0x00, 0x15 } },
  305.             { Graphics_CMD,   { "\x0\x0\x0\x0\x0\x0\x05\x0F\x0FF", 0x00, 0x09 } },
  306.             { Terminate_CMD }
  307.           }
  308.         },
  309.  
  310. // 80x26 EPOCH Color Emulation For Protect Mode
  311.         {
  312.           0x0F, 0x0F, 0, 26, 27, 0, 0, 1,
  313.           {
  314.             { RegOutput_CMD,  { "\xE3", MiscOutputRegWrite, 0x01 } },
  315.             { Sequencers_CMD, { "\x01\x01\x0F\x00\x06", 0x00, 0x04+1 } },
  316.             { CRTCtlRegs_CMD, { "\x05", 0x11, 0x01 } },
  317.             { CRTCtlRegs_CMD, { "\x5F\x4F\x50\x82\x54\x80\xB\x3E\x0\x40\x0\x0\x0\x0\x0\x0\xEA\x8C\xD3\x40\x0\xE7\x4\xC3\xFF", 0x00, 0x18+1 } },
  318.             { RegOutput_CMD,  { "\xE3", MiscOutputRegWrite, 0x01 } },
  319.             { Attributes_CMD, { "\x0\x1\x2\x3\x4\x5\x36\x7\x38\x39\x3A\x3B\x3C\x3D\x3E\x3F\x01\x0\x0F\x0\x0", 0x00, 0x15 } },
  320.             { Graphics_CMD,   { "\x0\x0\x0\x0\x0\x0\x05\x0F\x0FF", 0x00, 0x09 } },
  321.             { Terminate_CMD }
  322.           }
  323.         }
  324.     };
  325.  
  326. /*----------------------------------------------------------------------------*/
  327. /* Memory map table -                                                         */
  328. /*    typedef struct {                                                        */
  329. /*              ULONG      PageLength; ; Length of each page                  */
  330. /*              USHORT     PageReal;   ; Length of each page (Real Mode)      */
  331. /*              ULONG      TotalSize;  ; Total size of all pages combined     */
  332. /*              ULONG      TotalReal;  ; Total size of all pages (Real Mode)  */
  333. /*              USHORT     BitPlanes;  ; Flag byte of bit planes used         */
  334. /*              FarAddress Start;                                             */
  335. /*              } MEMORYMAPS;                                                 */
  336. /*                                                                            */
  337. /* These memory maps are used to save and restore the physical video buffer   */
  338. /*----------------------------------------------------------------------------*/
  339.  
  340. MEMORYMAPS MemoryMaps[] = {
  341. /*       {38400,0xA000, 153600,0x28000, 1+2+4+8, (char far *)0xA0000 }       */
  342. /*@S4*/  {0x10000,0xA000, 0x40000,0x28000, 1+2+4+8, (char far *)0xA0000 } /* 12 */
  343.         };
  344.  
  345. /*----------------------------------------------------------------------------*/
  346. /* Color table for Palette handling                                           */
  347. /*----------------------------------------------------------------------------*/
  348.  
  349. USHORT EpoPalette[16]
  350.  = { BG_Color,BGH_Color,FG_Color,FGH_Color,0xFF,0xFF,0xFF,0xFF,Cur_Color,0xFF,
  351.      0xFF,0xFF,0xFF,0xFF,0xFF,0xFF}; /*J-KK0905*/
  352.  
  353. //--- Epoch Mono Mode : Special Handling ---------------------------
  354. // Normal Fore Color  attr=2h --> Palette  FG_Color    ( Ah --> 2h J-KK1027 )
  355. // Normal Back Color  attr=0h --> Palette  BG_Color
  356. // H-Int  Fore Color  attr=Fh --> Palette  FGH_Color
  357. // H-Int  Back Color  attr=8h --> Palette  BGH_Color
  358. // Cursor      Color  attr=Eh --> Palette  Cur_Color
  359. //------------------------------------------------------------------
  360.  
  361. // Palette Registers Conversion Table                                 //J-KK1027
  362. USHORT CnvPalette[16]={ 0,8,4,0xC,2,0xA,6,0xE,1,9,5,0xD,3,0xB,7,0xF}; //J-KK1027
  363. //                    { 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15      }; //J-KK1027
  364.