/[rdesktop]/sourceforge.net/trunk/rdesktop/orders.h
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Contents of /sourceforge.net/trunk/rdesktop/orders.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 64 - (show annotations)
Thu Jul 18 16:38:31 2002 UTC (21 years, 10 months ago) by astrand
File MIME type: text/plain
File size: 4514 byte(s)
Fixed indentation with indent

1 /*
2 rdesktop: A Remote Desktop Protocol client.
3 RDP order processing
4 Copyright (C) Matthew Chapman 1999-2000
5
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version.
10
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
19 */
20
21 #define RDP_ORDER_STANDARD 0x01
22 #define RDP_ORDER_SECONDARY 0x02
23 #define RDP_ORDER_BOUNDS 0x04
24 #define RDP_ORDER_CHANGE 0x08
25 #define RDP_ORDER_DELTA 0x10
26 #define RDP_ORDER_LASTBOUNDS 0x20
27 #define RDP_ORDER_SMALL 0x40
28 #define RDP_ORDER_TINY 0x80
29
30 enum RDP_ORDER_TYPE
31 {
32 RDP_ORDER_DESTBLT = 0,
33 RDP_ORDER_PATBLT = 1,
34 RDP_ORDER_SCREENBLT = 2,
35 RDP_ORDER_LINE = 9,
36 RDP_ORDER_RECT = 10,
37 RDP_ORDER_DESKSAVE = 11,
38 RDP_ORDER_MEMBLT = 13,
39 RDP_ORDER_TRIBLT = 14,
40 RDP_ORDER_POLYLINE = 22,
41 RDP_ORDER_TEXT2 = 27
42 };
43
44 enum RDP_SECONDARY_ORDER_TYPE
45 {
46 RDP_ORDER_RAW_BMPCACHE = 0,
47 RDP_ORDER_COLCACHE = 1,
48 RDP_ORDER_BMPCACHE = 2,
49 RDP_ORDER_FONTCACHE = 3
50 };
51
52 typedef struct _DESTBLT_ORDER
53 {
54 uint16 x;
55 uint16 y;
56 uint16 cx;
57 uint16 cy;
58 uint8 opcode;
59
60 }
61 DESTBLT_ORDER;
62
63 typedef struct _PATBLT_ORDER
64 {
65 uint16 x;
66 uint16 y;
67 uint16 cx;
68 uint16 cy;
69 uint8 opcode;
70 uint8 bgcolour;
71 uint8 fgcolour;
72 BRUSH brush;
73
74 }
75 PATBLT_ORDER;
76
77 typedef struct _SCREENBLT_ORDER
78 {
79 uint16 x;
80 uint16 y;
81 uint16 cx;
82 uint16 cy;
83 uint8 opcode;
84 uint16 srcx;
85 uint16 srcy;
86
87 }
88 SCREENBLT_ORDER;
89
90 typedef struct _LINE_ORDER
91 {
92 uint16 mixmode;
93 uint16 startx;
94 uint16 starty;
95 uint16 endx;
96 uint16 endy;
97 uint8 bgcolour;
98 uint8 opcode;
99 PEN pen;
100
101 }
102 LINE_ORDER;
103
104 typedef struct _RECT_ORDER
105 {
106 uint16 x;
107 uint16 y;
108 uint16 cx;
109 uint16 cy;
110 uint8 colour;
111
112 }
113 RECT_ORDER;
114
115 typedef struct _DESKSAVE_ORDER
116 {
117 uint32 offset;
118 uint16 left;
119 uint16 top;
120 uint16 right;
121 uint16 bottom;
122 uint8 action;
123
124 }
125 DESKSAVE_ORDER;
126
127 typedef struct _TRIBLT_ORDER
128 {
129 uint8 colour_table;
130 uint8 cache_id;
131 uint16 x;
132 uint16 y;
133 uint16 cx;
134 uint16 cy;
135 uint8 opcode;
136 uint16 srcx;
137 uint16 srcy;
138 uint8 bgcolour;
139 uint8 fgcolour;
140 BRUSH brush;
141 uint16 cache_idx;
142 uint16 unknown;
143
144 }
145 TRIBLT_ORDER;
146
147 typedef struct _MEMBLT_ORDER
148 {
149 uint8 colour_table;
150 uint8 cache_id;
151 uint16 x;
152 uint16 y;
153 uint16 cx;
154 uint16 cy;
155 uint8 opcode;
156 uint16 srcx;
157 uint16 srcy;
158 uint16 cache_idx;
159
160 }
161 MEMBLT_ORDER;
162
163 #define MAX_DATA 256
164
165 typedef struct _POLYLINE_ORDER
166 {
167 uint16 x;
168 uint16 y;
169 uint8 flags;
170 uint8 fgcolour;
171 uint8 lines;
172 uint8 datasize;
173 uint8 data[MAX_DATA];
174
175 }
176 POLYLINE_ORDER;
177
178 #define MAX_TEXT 256
179
180 typedef struct _TEXT2_ORDER
181 {
182 uint8 font;
183 uint8 flags;
184 uint8 mixmode;
185 uint8 unknown;
186 uint8 fgcolour;
187 uint8 bgcolour;
188 uint16 clipleft;
189 uint16 cliptop;
190 uint16 clipright;
191 uint16 clipbottom;
192 uint16 boxleft;
193 uint16 boxtop;
194 uint16 boxright;
195 uint16 boxbottom;
196 uint16 x;
197 uint16 y;
198 uint8 length;
199 uint8 text[MAX_TEXT];
200
201 }
202 TEXT2_ORDER;
203
204 typedef struct _RDP_ORDER_STATE
205 {
206 uint8 order_type;
207 BOUNDS bounds;
208
209 DESTBLT_ORDER destblt;
210 PATBLT_ORDER patblt;
211 SCREENBLT_ORDER screenblt;
212 LINE_ORDER line;
213 RECT_ORDER rect;
214 DESKSAVE_ORDER desksave;
215 MEMBLT_ORDER memblt;
216 TRIBLT_ORDER triblt;
217 POLYLINE_ORDER polyline;
218 TEXT2_ORDER text2;
219
220 }
221 RDP_ORDER_STATE;
222
223 typedef struct _RDP_RAW_BMPCACHE_ORDER
224 {
225 uint8 cache_id;
226 uint8 pad1;
227 uint8 width;
228 uint8 height;
229 uint8 bpp;
230 uint16 bufsize;
231 uint16 cache_idx;
232 uint8 *data;
233
234 }
235 RDP_RAW_BMPCACHE_ORDER;
236
237 typedef struct _RDP_BMPCACHE_ORDER
238 {
239 uint8 cache_id;
240 uint8 pad1;
241 uint8 width;
242 uint8 height;
243 uint8 bpp;
244 uint16 bufsize;
245 uint16 cache_idx;
246 uint16 pad2;
247 uint16 size;
248 uint16 row_size;
249 uint16 final_size;
250 uint8 *data;
251
252 }
253 RDP_BMPCACHE_ORDER;
254
255 #define MAX_GLYPH 32
256
257 typedef struct _RDP_FONT_GLYPH
258 {
259 uint16 character;
260 uint16 unknown;
261 uint16 baseline;
262 uint16 width;
263 uint16 height;
264 uint8 data[MAX_GLYPH];
265
266 }
267 RDP_FONT_GLYPH;
268
269 #define MAX_GLYPHS 256
270
271 typedef struct _RDP_FONTCACHE_ORDER
272 {
273 uint8 font;
274 uint8 nglyphs;
275 RDP_FONT_GLYPH glyphs[MAX_GLYPHS];
276
277 }
278 RDP_FONTCACHE_ORDER;
279
280 typedef struct _RDP_COLCACHE_ORDER
281 {
282 uint8 cache_id;
283 COLOURMAP map;
284
285 }
286 RDP_COLCACHE_ORDER;

  ViewVC Help
Powered by ViewVC 1.1.26