VirtualBox

source: vbox/trunk/include/VBox/VRDPOrders.h@ 7581

Last change on this file since 7581 was 7133, checked in by vboxsync, 17 years ago

Eliminate cpum.h dependency (shuts up a bunch of .c warnings). Fixed the header tests.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 6.3 KB
Line 
1/** @file
2 * VBox Remote Desktop Protocol:
3 * VRDP orders structures.
4 */
5
6/*
7 * Copyright (C) 2006-2008 innotek GmbH
8 *
9 * This file is part of VirtualBox Open Source Edition (OSE), as
10 * available from http://www.virtualbox.org. This file is free software;
11 * you can redistribute it and/or modify it under the terms of the GNU
12 * General Public License (GPL) as published by the Free Software
13 * Foundation, in version 2 as it comes in the "COPYING" file of the
14 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16 *
17 * The contents of this file may alternatively be used under the terms
18 * of the Common Development and Distribution License Version 1.0
19 * (CDDL) only, as it comes in the "COPYING.CDDL" file of the
20 * VirtualBox OSE distribution, in which case the provisions of the
21 * CDDL are applicable instead of those of the GPL.
22 *
23 * You may elect to license modified versions of this file under the
24 * terms and conditions of either the GPL or the CDDL or both.
25 */
26
27#ifndef ___VBox_vrdporders_h
28#define ___VBox_vrdporders_h
29
30#include <iprt/types.h>
31
32/*
33 * The VRDP server gets an information about a graphical update as a pointer
34 * to a memory block and the size of the memory block.
35 * The memory block layout is:
36 * VRDPORDERHDR - Describes the affected rectangle.
37 * Then VRDP orders follow:
38 * VRDPORDERCODE
39 * A VRDPORDER* structure.
40 *
41 * If size of the memory block is equal to the VRDPORDERHDR, then a bitmap
42 * update is assumed.
43 */
44
45/* 128 bit bitmap hash. */
46typedef uint8_t VRDPBITMAPHASH[16];
47
48#pragma pack(1)
49typedef struct _VRDPORDERHDR
50{
51 /** Coordinates of the affected rectangle. */
52 int16_t x;
53 int16_t y;
54 uint16_t w;
55 uint16_t h;
56} VRDPORDERHDR;
57
58typedef struct _VRDPORDERCODE
59{
60 uint32_t u32Code;
61} VRDPORDERCODE;
62
63/* VRDP order codes. Must be >= 0, because the VRDP server internally
64 * uses negative values to mark some operations.
65 */
66#define VRDP_ORDER_DIRTY_RECT (0)
67#define VRDP_ORDER_SOLIDRECT (1)
68#define VRDP_ORDER_SOLIDBLT (2)
69#define VRDP_ORDER_DSTBLT (3)
70#define VRDP_ORDER_SCREENBLT (4)
71#define VRDP_ORDER_PATBLTBRUSH (5)
72#define VRDP_ORDER_MEMBLT (6)
73#define VRDP_ORDER_CACHED_BITMAP (7)
74#define VRDP_ORDER_DELETED_BITMAP (8)
75#define VRDP_ORDER_LINE (9)
76#define VRDP_ORDER_BOUNDS (10)
77#define VRDP_ORDER_REPEAT (11)
78#define VRDP_ORDER_POLYLINE (12)
79#define VRDP_ORDER_ELLIPSE (13)
80#define VRDP_ORDER_SAVESCREEN (14)
81#define VRDP_ORDER_TEXT (15)
82
83typedef struct _VRDPORDERPOINT
84{
85 int16_t x;
86 int16_t y;
87} VRDPORDERPOINT;
88
89typedef struct _VRDPORDERPOLYPOINTS
90{
91 uint8_t c;
92 VRDPORDERPOINT a[16];
93} VRDPORDERPOLYPOINTS;
94
95typedef struct _VRDPORDERAREA
96{
97 int16_t x;
98 int16_t y;
99 uint16_t w;
100 uint16_t h;
101} VRDPORDERAREA;
102
103typedef struct _VRDPORDERRECT
104{
105 int16_t left;
106 int16_t top;
107 int16_t right;
108 int16_t bottom;
109} VRDPORDERRECT;
110
111
112typedef struct _VRDPORDERBOUNDS
113{
114 VRDPORDERPOINT pt1;
115 VRDPORDERPOINT pt2;
116} VRDPORDERBOUNDS;
117
118typedef struct _VRDPORDERREPEAT
119{
120 VRDPORDERBOUNDS bounds;
121} VRDPORDERREPEAT;
122
123
124/* Header for bitmap bits in VBVA VRDP operations. */
125typedef struct _VRDPDATABITS
126{
127 /* Size of bitmap data without the header. */
128 uint32_t cb;
129 int16_t x;
130 int16_t y;
131 uint16_t cWidth;
132 uint16_t cHeight;
133 uint8_t cbPixel;
134} VRDPDATABITS;
135
136typedef struct _VRDPORDERSOLIDRECT
137{
138 int16_t x;
139 int16_t y;
140 uint16_t w;
141 uint16_t h;
142 uint32_t rgb;
143} VRDPORDERSOLIDRECT;
144
145typedef struct _VRDPORDERSOLIDBLT
146{
147 int16_t x;
148 int16_t y;
149 uint16_t w;
150 uint16_t h;
151 uint32_t rgb;
152 uint8_t rop;
153} VRDPORDERSOLIDBLT;
154
155typedef struct _VRDPORDERDSTBLT
156{
157 int16_t x;
158 int16_t y;
159 uint16_t w;
160 uint16_t h;
161 uint8_t rop;
162} VRDPORDERDSTBLT;
163
164typedef struct _VRDPORDERSCREENBLT
165{
166 int16_t x;
167 int16_t y;
168 uint16_t w;
169 uint16_t h;
170 int16_t xSrc;
171 int16_t ySrc;
172 uint8_t rop;
173} VRDPORDERSCREENBLT;
174
175typedef struct _VRDPORDERPATBLTBRUSH
176{
177 int16_t x;
178 int16_t y;
179 uint16_t w;
180 uint16_t h;
181 int8_t xSrc;
182 int8_t ySrc;
183 uint32_t rgbFG;
184 uint32_t rgbBG;
185 uint8_t rop;
186 uint8_t pattern[8];
187} VRDPORDERPATBLTBRUSH;
188
189typedef struct _VRDPORDERMEMBLT
190{
191 int16_t x;
192 int16_t y;
193 uint16_t w;
194 uint16_t h;
195 int16_t xSrc;
196 int16_t ySrc;
197 uint8_t rop;
198 VRDPBITMAPHASH hash;
199} VRDPORDERMEMBLT;
200
201typedef struct _VRDPORDERCACHEDBITMAP
202{
203 VRDPBITMAPHASH hash;
204 /* VRDPDATABITS and the bitmap data follows. */
205} VRDPORDERCACHEDBITMAP;
206
207typedef struct _VRDPORDERDELETEDBITMAP
208{
209 VRDPBITMAPHASH hash;
210} VRDPORDERDELETEDBITMAP;
211
212typedef struct _VRDPORDERLINE
213{
214 int16_t x1;
215 int16_t y1;
216 int16_t x2;
217 int16_t y2;
218 int16_t xBounds1;
219 int16_t yBounds1;
220 int16_t xBounds2;
221 int16_t yBounds2;
222 uint8_t mix;
223 uint32_t rgb;
224} VRDPORDERLINE;
225
226typedef struct _VRDPORDERPOLYLINE
227{
228 VRDPORDERPOINT ptStart;
229 uint8_t mix;
230 uint32_t rgb;
231 VRDPORDERPOLYPOINTS points;
232} VRDPORDERPOLYLINE;
233
234typedef struct _VRDPORDERELLIPSE
235{
236 VRDPORDERPOINT pt1;
237 VRDPORDERPOINT pt2;
238 uint8_t mix;
239 uint8_t fillMode;
240 uint32_t rgb;
241} VRDPORDERELLIPSE;
242
243typedef struct _VRDPORDERSAVESCREEN
244{
245 VRDPORDERPOINT pt1;
246 VRDPORDERPOINT pt2;
247 uint8_t ident;
248 uint8_t restore;
249} VRDPORDERSAVESCREEN;
250
251typedef struct _VRDPORDERGLYPH
252{
253 uint32_t o32NextGlyph;
254 uint64_t u64Handle;
255
256 /* The glyph origin position on the screen. */
257 int16_t x;
258 int16_t y;
259
260 /* The glyph bitmap dimensions. Note w == h == 0 for the space character. */
261 uint16_t w;
262 uint16_t h;
263
264 /* The character origin in the bitmap. */
265 int16_t xOrigin;
266 int16_t yOrigin;
267
268 /* 1BPP bitmap. Rows are byte aligned. Size is (((w + 7)/8) * h + 3) & ~3. */
269 uint8_t au8Bitmap[1];
270} VRDPORDERGLYPH;
271
272typedef struct _VRDPORDERTEXT
273{
274 uint32_t cbOrder;
275
276 int16_t xBkGround;
277 int16_t yBkGround;
278 uint16_t wBkGround;
279 uint16_t hBkGround;
280
281 int16_t xOpaque;
282 int16_t yOpaque;
283 uint16_t wOpaque;
284 uint16_t hOpaque;
285
286 uint16_t u16MaxGlyph;
287
288 uint8_t u8Glyphs;
289 uint8_t u8Flags;
290 uint16_t u8CharInc;
291 uint32_t u32FgRGB;
292 uint32_t u32BgRGB;
293
294 /* u8Glyphs glyphs follow. Size of each glyph structure may vary. */
295} VRDPORDERTEXT;
296#pragma pack()
297
298#endif
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette