diff options
| author | Jay Sorg <jay.sorg@gmail.com> | 2014-02-18 12:10:05 -0800 |
|---|---|---|
| committer | Jay Sorg <jay.sorg@gmail.com> | 2014-02-18 12:10:05 -0800 |
| commit | 8cd57e07102a048d1e4b8ae4228a4cbdde88d509 (patch) | |
| tree | 1b1e955c4a04ad1260c1a744655b184a27d17505 /xrdp | |
| parent | b0a18321864ad8dc3f2308d2c920f85e2500f5d1 (diff) | |
| download | xrdp-proprietary-8cd57e07102a048d1e4b8ae4228a4cbdde88d509.tar.gz xrdp-proprietary-8cd57e07102a048d1e4b8ae4228a4cbdde88d509.zip | |
added server_paint_rects
Diffstat (limited to 'xrdp')
| -rw-r--r-- | xrdp/xrdp.h | 4 | ||||
| -rw-r--r-- | xrdp/xrdp_mm.c | 33 | ||||
| -rw-r--r-- | xrdp/xrdp_types.h | 6 |
3 files changed, 42 insertions, 1 deletions
diff --git a/xrdp/xrdp.h b/xrdp/xrdp.h index e04dea5f..0897879f 100644 --- a/xrdp/xrdp.h +++ b/xrdp/xrdp.h @@ -402,6 +402,10 @@ server_composite(struct xrdp_mod* mod, int srcidx, int srcformat, int srcwidth, int srcx, int srcy, int mskx, int msky, int dstx, int dsty, int width, int height, int dstformat); int DEFAULT_CC +server_paint_rects(struct xrdp_mod* mod, int num_drects, short *drects, + int num_crects, short *crects, + char *data, int width, int height, int flags); +int DEFAULT_CC server_set_pointer(struct xrdp_mod* mod, int x, int y, char* data, char* mask); int DEFAULT_CC diff --git a/xrdp/xrdp_mm.c b/xrdp/xrdp_mm.c index 6a1fd323..494d79d3 100644 --- a/xrdp/xrdp_mm.c +++ b/xrdp/xrdp_mm.c @@ -417,6 +417,7 @@ xrdp_mm_setup_mod1(struct xrdp_mm *self) self->mod->server_create_os_surface_bpp = server_create_os_surface_bpp; self->mod->server_paint_rect_bpp = server_paint_rect_bpp; self->mod->server_composite = server_composite; + self->mod->server_paint_rects = server_paint_rects; } } @@ -2138,6 +2139,38 @@ server_composite(struct xrdp_mod* mod, int srcidx, int srcformat, /*****************************************************************************/ int DEFAULT_CC +server_paint_rects(struct xrdp_mod* mod, int num_drects, short *drects, + int num_crects, short *crects, + char *data, int width, int height, int flags) +{ + struct xrdp_wm* wm; + struct xrdp_painter* p; + struct xrdp_bitmap *b; + short *s; + int index; + + //g_writeln("server_paint_rects:"); + wm = (struct xrdp_wm*)(mod->wm); + p = (struct xrdp_painter*)(mod->painter); + if (p == 0) + { + return 0; + } + b = xrdp_bitmap_create_with_data(width, height, wm->screen->bpp, + data, wm); + s = crects; + for (index = 0; index < num_crects; index++) + { + xrdp_painter_copy(p, b, wm->target_surface, s[0], s[1], s[2], s[3], + s[0], s[1]); + s += 4; + } + xrdp_bitmap_delete(b); + return 0; +} + +/*****************************************************************************/ +int DEFAULT_CC server_set_pointer(struct xrdp_mod *mod, int x, int y, char *data, char *mask) { diff --git a/xrdp/xrdp_types.h b/xrdp/xrdp_types.h index 0f0227b8..7d7eb72c 100644 --- a/xrdp/xrdp_types.h +++ b/xrdp/xrdp_types.h @@ -139,7 +139,11 @@ struct xrdp_mod int srcx, int srcy, int mskx, int msky, int dstx, int dsty, int width, int height, int dstformat); - long server_dumby[100 - 42]; /* align, 100 minus the number of server + int (*server_paint_rects)(struct xrdp_mod* v, + int num_drects, short *drects, + int num_crects, short *crects, + char *data, int width, int height, int flags); + long server_dumby[100 - 43]; /* align, 100 minus the number of server functions above */ /* common */ long handle; /* pointer to self as int */ |
