⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 metconst.h

📁 与Nucleus Plus配套的图形库
💻 H
📖 第 1 页 / 共 2 页
字号:
/**********************************************************************/
/*                                                                    */
/*        Copyright (c) 1991-1999 Mike Manning                        */
/*                                                                    */
/* PROPRIETARY RIGHTS of Mike Manning are involved in the subject     */
/* matter of this material.  All manufacturing, reproduction, use,    */
/* and sales rights pertaining to this subject matter are governed    */
/* by the license agreement.  The recipient of this software          */
/* implicitly accepts the terms of the license.                       */
/*--------------------------------------------------------------------*/
/*                                                                    */
/* Licensed to Accelerated Technology, Inc. for Distribution 09/1997  */
/**********************************************************************/

/**********************************************************************/
/*                                                                    */
/*    FileName: METCONST.H                                            */
/*                                                                    */
/*--------------------------------------------------------------------*/
/*                                                                    */
/*    Description    : Header file for GRAFIX  toolbox, contains      */
/*                     includes for all toolbox header files.         */
/*--------------------------------------------------------------------*/
/*                                                                    */
/*    Author         : Bob Burrill                                    */
/*    developed on   : 05/20/1998                                     */
/*                                                                    */
/**********************************************************************/

#ifndef  MS_DOS
!!!Error!!!  You must use METAWNDO.H include file
#endif /*MS_DOS*/

#ifndef BPP
#include "config.h"
#endif

#define  Byte    unsigned char  /* "Byte" type (8 bits)      */
#define  Word    unsigned short /* "Word" type (16 bits)     */

/*=======================================*/
/* Graphics Adaptor Definitions          */
/*=======================================*/

#define cMET                0x0000
#define cNODEVICE          (cMET+0)      /* no graphics device required   */
#define cMEMORY            (cMET+1)      /* Conventional Memory grafMap   */
#define cLCD               (0x100)      /* Generic LCD grafMap           */
#define cUSER              (cMET+3)      /* User Defined grafmap          */   
#define cDISK              (cMET+4)      /* Disk Based grafMap            */

/*=======================================*/
/*           IBM and compatibles         */
/*=======================================*/
#define cIBM                  0x0C00
#define CGA640x200         (cIBM+0x21)   /* CGA 640x200 2-color         */
#define EGA320x200         (cIBM+0x12)   /* EGA 320x200 16-color        */
#define EGA640x200         (cIBM+0x22)   /* EGA 640x200 16-color        */
#define EGA640x350         (cIBM+0x32)   /* EGA 640x350 16-color (128k) */
#define EGAMono            (cIBM+0x42)   /* EGA 640x350 (monochrome)    */
#define EGA640x350MP       (cIBM+0x52)   /* EGA as a multiplane device  */
#define EGA640x3502        (cIBM+0x62)   /* EGA 640x350  2-color (128k) */
#define VGA320x200         (cIBM+0x13)   /* VGA 320x200 16-color        */
#define VGA640x200         (cIBM+0x23)   /* VGA 640x200 16-color        */
#define VGA640x350         (cIBM+0x33)   /* VGA 640x350 16-color        */
#define VGA640x480         (cIBM+0x43)   /* VGA 640x480 16-color        */
#define VGA640x4802        (cIBM+0x53)   /* VGA 640x480 2-color (MCGA)  */
#define VGA320x200X        (cIBM+0x63)   /* VGA 320x200 256-color (PS2) */
#define TTS720x350         (cIBM+0x14)   /* IBM 3270 PC  720x350 mono   */


/*=======================================*/
/*     Input Device Definitions          */
/*=======================================*/
#define MsDriver           0x01          /*  Mouse Driver Ver. 6.0 or >  */
#define MoCOM1             0x11          /*  Mouse Systems/Logitec COM1  */
#define MoCOM2             0x21          /*  Mouse Systems/Logitec COM2  */
#define MsCOM1             0x31          /*  Microsoft Serial Mouse COM1 */
#define MsCOM2             0x41          /*  Microsoft Serial Mouse COM2 */
#define JoyStick           0x04          /*  Joystick on game port       */



/* ----- RASTEROP, PENMODE & TEXTMODE Pixel Operations ----- */

#define zREPz          0   /*       src                      */
#define zORz           1   /*       src     OR      dst      */
#define zXORz          2   /*       src     XOR     dst      */
#define zNANDz         3   /*    (NOT src)  AND     dst      */
#define zNREPz         4   /*    (NOT src)                   */
#define zNORz          5   /*    (NOT src)  OR      dst      */
#define zNXORz         6   /*    (NOT src)  XOR     dst      */
#define zANDz          7   /*       src     AND     dst      */
#define zCLEARz        8   /*               0s               */
#define zORNz          9   /*       src     OR   (NOT dst)   */
#define zNOPz         10   /*                       dst      */
#define zANDNz        11   /*       src     AND  (NOT dst)   */
#define zSETz         12   /*               1s               */
#define zNORNz        13   /*    (NOT src)  OR   (NOT dst)   */
#define zINVERTz      14   /*                    (NOT dst)   */
#define zNANDNz       15   /*    (NOT src)  AND  (NOT dst)   */

/* Source monochrome "Transparent" rasterOp Operations */
#define xREPx         16   /*    (!0src)                     */
#define xORx          17   /*    (!0src)    OR      dst      */
#define xXORx         18   /*    (!0src)    XOR     dst      */
#define xNANDx        19   /*  (NOT !0src)  AND     dst      */
#define xNREPx        20   /*  (NOT !0src)                   */
#define xNORx         21   /*  (NOT !0src)  OR      dst      */
#define xNXORx        22   /*  (NOT !0src)  XOR     dst      */
#define xANDx         23   /*    (!0src)    AND     dst      */
#define xCLEARx       24   /*                       dst      */
#define xORNx         25   /*    (!0src)    OR   (NOT dst)   */
#define xNOPx         26   /*                       dst      */
#define xANDNx        27   /*    (!0src)    AND  (NOT dst)   */
#define xSETx         28   /*               1s               */
#define xNORNx        29   /*  (NOT !0src)  OR   (NOT dst)   */
#define xINVERTx      30   /*                    (NOT dst)   */
#define xNANDNx       31   /*  (NOT !0src)  AND  (NOT dst)   */
        

/* ----------------------- Text System Defines ------------- */

#define cNormal         0  /* "TextFace" definitions         */
#define cBold           1
#define cItalic         2
#define cUnderline      4
#define cStrikeout      8
#define cHalftone      16
#define cMirrorX       32
#define cMirrorY       64
#define cProportional 128

#define alignLeft       0  /* "TextAlign" - Horizontal       */
#define alignCenter     1
#define alignRight      2

#define alignBaseline   0  /* "TextAlign" - Vertical         */
#define alignBottom     1
#define alignMiddle     2
#define alignTop        3

#define pathRight       0  /* "TextPath" definitions         */
#define pathUp        900
#define pathLeft     1800
#define pathDown     2700


/* ---------------- System structures & defines ------------ */

#define True            1
#define False           0

#if (BPP == 8)
#define Black          0
#define Blue           10
#define Green          9
#define Cyan           12
#define Red            8
#define Magenta        13
#define Brown          11
#define LtGray         7
#define Gray           14
#define LtBlue         3
#define LtGreen        2
#define LtCyan         5
#define LtRed          1
#define LtMagenta      6
#define Yellow         4
#define White          15

#elif (BPP == 16)
/* 15-bit color for MNT */
#define Black          0x0000
#define Blue           0x0010
#define Green          0x0200
#define Cyan           0x0210
#define Red            0x4000
#define Magenta        0x4010
#define Brown          0x4103
#define LtGray         0x6318
#define Gray           0x4210
#define LtBlue         0x001f
#define LtGreen        0x03e0
#define LtCyan         0x03ff
#define LtRed          0x7c00
#define LtMagenta      0x7c1f
#define Yellow         0x7fe0
#define White          0xffff
/* 565 16-bit color */
/*#define Black          0x0000
#define Blue           0x0010
#define Green          0x0400
#define Cyan           0x0410
#define Red            0x8000
#define Magenta        0x8010
#define Brown          0x8203
#define LtGray         0xc618
#define Gray           0x8410
#define LtBlue         0x001f
#define LtGreen        0x07e0
#define LtCyan         0x07ff
#define LtRed          0xf800
#define LtMagenta      0xf81f
#define Yellow         0xffe0
#define White          0xffff*/

#elif (BPP == 24)
/* reversed RGB for MNT */
#define Black          0x000000
#define Blue           0x800000
#define Green          0x008000
#define Cyan           0x808000
#define Red            0x000080
#define Magenta        0x800080
#define Brown          0x208080
#define LtGray         0xb0b0b0
#define Gray           0x808080
#define LtBlue         0xff0000
#define LtGreen        0x00ff00
#define LtCyan         0xffff00
#define LtRed          0x0000ff
#define LtMagenta      0xff00ff
#define Yellow         0x00ffff
#define White          0xffffff
/* forward RGB */
/*#define Black          0x000000
#define Blue           0x000080
#define Green          0x008000
#define Cyan           0x008080
#define Red            0x800000
#define Magenta        0x800080
#define Brown          0x808020
#define LtGray         0xb0b0b0
#define Gray           0x808080
#define LtBlue         0x0000ff
#define LtGreen        0x00ff00
#define LtCyan         0x00ffff
#define LtRed          0xff0000
#define LtMagenta      0xff00ff
#define Yellow         0xffff00
#define White          0xffffff*/

#endif

#define TextPg          0
#define TextPg0         0
#define GrafPg        256

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -