File: headers\tplus.h
1 /* TPLUS.H, (C) 1991 The Yankee Programmer
2 All Rights Reserved
3
4 This code may be distributed only when bundled with the Fractint
5 source code.
6
7 Mark C. Peterson
8 The Yankee Programmer
9 405-C Queen Street, Suite #181
10 Southington, CT 06489
11 (203) 276-9721
12
13 */
14
15 #ifndef TPLUS_H
16 #define TPLUS_H
17
18 #ifdef CTL
19 #undef CTL
20 #endif
21
22 #ifdef __TURBOC__
27 #else
28 #define OUTPORTB outp
29 #define INPORTB inp
30 #define OUTPORTW outpw
31 #define INPORTW inpw
32 #endif
33
34 struct TPWrite {
35 unsigned
36 COLOR0, COLOR1, COLOR2, COLOR3, VIDCON, INDIRECT, HUESAT,
37 OVSTRT, MASKL, MASKH, LBNK, HBNK, MODE1, MODE2,
38 WBL, WBH;
39 };
40
41 struct TPRead {
42 unsigned
43 VIDSTAT, CTL, MASKL, LBNK, READAD, MODE1,
44 OVSTRT, USCAN, MASKH, OSCAN, HBNK, ROWCNT, MODE2,
45 RBL, RBH;
46 };
47
48 /* TPlus Register Data Offsets */
49 #define XDOTS 0
50 #define YDOTS 1
51 #define ASP_RATIO 2
52 #define DEPTH 4
53 #define PAGE 5
54 #define BOTBANK 7
55 #define TOPBANK 8
56 #define ZOOM 10
57 #define DISPMODE 11
58 #define DAC567DATA 15
59 #define VTOP 19
60 #define TOP 51
61 #define BOT 53
62 #define VPAN 55
63 #define NOT_INT 56
64 #define HIRES 61
65 #define PERM 64
66 #define BYCAP 68
67 #define PE 69
68 #define OVLE 70
69 #define HPAN 71
70 #define MEM_BASE 73
71 #define MEM_MAP 74
72 #define LIVEMIXSRC 91
73 #define RGB 93
74 #define SVIDEO 97
75 #define BUFFPORTSRC 98
76 #define CM1 101
77 #define CM2 102
78 #define LUTBYPASS 107
79 #define CM3 113
80 #define LIVEPORTSRC 115
81 #define LIVE8 116
82 #define VGASRC 123
83
84 struct _BOARD {
85 int ThisBoard, ClearScreen;
86 BYTE far *Screen;
87 unsigned VerPan, HorPan, Top, Bottom;
88 unsigned xdots, ydots, Bank64k, RowBytes, RowsPerBank;
89 unsigned Reg[128];
90 #ifndef XFRACT
91 void (*Plot)(int x, int y, unsigned long Color);
92 unsigned long (*GetColor)(int x, int y);
96 #endif
97
98 struct TPRead Read;
99 struct TPWrite Write;
100 };
101
102 extern struct _BOARD far TPlus;
103
104 #endif
105