/[projet1]/public/pc/tools/osdk/main/Osdk/_final_/include2/sys/graphics.h
Defence Force logotype

Contents of /public/pc/tools/osdk/main/Osdk/_final_/include2/sys/graphics.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1159 - (show annotations)
Sun Aug 10 18:31:35 2014 UTC (5 years, 3 months ago) by dbug
File MIME type: text/plain
File size: 2473 byte(s)


1 /* sys/graphics.h */
2
3 /* Routines needed for Oric text, lores or hires graphics */
4
5 #ifndef _SYS_GRAPHICS_
6
7 #define _SYS_GRAPHICS_
8
9
10 /* Serial Attributes, curses style :-| */
11
12 #define A_FWBLACK 0
13 #define A_FWRED 1
14 #define A_FWGREEN 2
15 #define A_FWYELLOW 3
16 #define A_FWBLUE 4
17 #define A_FWMAGENTA 5
18 #define A_FWCYAN 6
19 #define A_FWWHITE 7
20 #define A_BGBLACK 16
21 #define A_BGRED 17
22 #define A_BGGREEN 18
23 #define A_BGYELLOW 19
24 #define A_BGBLUE 20
25 #define A_BGMAGENTA 21
26 #define A_BGCYAN 22
27 #define A_BGWHITE 23
28 #define A_STD 8
29 #define A_ALT 9
30 #define A_STD2H 10
31 #define A_ALT2H 11
32 #define A_STDFL 12
33 #define A_ALTFL 13
34 #define A_STD2HFL 14
35 #define A_ALT2HFL 15
36 #define A_TEXT60 24
37 #define A_TEXT50 26
38 #define A_HIRES60 28
39 #define A_HIRES50 30
40
41
42 /* Switch the screen to HIRES mode. */
43
44 extern void hires(void);
45
46
47 /* Switch the screen to TEXT mode. */
48
49 extern void text(void);
50
51
52 /* Select the INK (foreground) colour. */
53
54 extern int ink(int color);
55
56
57 /* Select the PAPER (background) colour. */
58
59 extern int paper(int color);
60
61
62 /* Set the position of the graphics cursor. */
63
64 /* The mode argument can be one of the following: */
65
66 #define MODE_RESET 0
67 #define MODE_SET 1
68 #define MODE_XOR 2
69 #define MODE_NONE 3
70
71
72 extern int curset(int x,int y,int mode);
73
74
75 /* Move the graphics cursor to a new location. */
76
77 /* The new location is given RELATIVE to the current position. */
78 /* That is, you can use negative numbers. */
79
80 extern int curmov(int dx,int dy,int mode);
81
82
83 /* Move the cursor to a new location as in curmov(), and draw a line */
84 /* between the current and new locations. */
85
86 extern int draw(int dx,int dy,int mode);
87
88
89 /* Draw a circle of given radius at the current cursor location. */
90
91 extern int circle(int radius,int mode);
92
93
94 /* Draw the character c of the given character set at the current */
95 /* cursor position. */
96
97 extern int hchar(char c,int charset,int mode);
98
99
100 /* Fill an area with an attribute or bit pattern. */
101
102 /* Width is in bytes, NOT pixels. */
103
104 extern int fill(int height,int width,char c);
105
106
107 /* Returns the bit value (ON/OFF) of the given pixel. */
108
109 extern int point(int x,int y);
110
111
112 /* Sets the 6-bit pattern used for drawing lines and circles. */
113
114 extern int pattern(char style);
115
116
117 #endif /* _SYS_GRAPHICS_ */
118
119 /* end of file sys/graphics.h */
120

  ViewVC Help
Powered by ViewVC 1.1.26