diff options
| author | Jim Grandy <jgrandy@authentic8.com> | 2013-07-03 10:45:46 -0700 |
|---|---|---|
| committer | Jim Grandy <jgrandy@authentic8.com> | 2013-08-22 12:49:41 -0700 |
| commit | 1ae9a7f2b685a8c2bf052e7c1724811346189fb9 (patch) | |
| tree | 6bc1e24c8b2b196206d8ddd46db00514dde7cb85 /libxrdp | |
| parent | a32669f3ef8752d952c9d31f55a667581ae93007 (diff) | |
| download | xrdp-proprietary-1ae9a7f2b685a8c2bf052e7c1724811346189fb9.tar.gz xrdp-proprietary-1ae9a7f2b685a8c2bf052e7c1724811346189fb9.zip | |
Hand-apply patches (drawing configuration) from Authentic8 branch: 34b92df f994298 38e2def
Diffstat (limited to 'libxrdp')
| -rw-r--r-- | libxrdp/libxrdp.h | 1 | ||||
| -rw-r--r-- | libxrdp/xrdp_orders.c | 9 | ||||
| -rw-r--r-- | libxrdp/xrdp_rdp.c | 10 |
3 files changed, 16 insertions, 4 deletions
diff --git a/libxrdp/libxrdp.h b/libxrdp/libxrdp.h index d31edbb4..83d3285c 100644 --- a/libxrdp/libxrdp.h +++ b/libxrdp/libxrdp.h @@ -211,6 +211,7 @@ struct xrdp_orders int order_count; int order_level; /* inc for every call to xrdp_orders_init */ struct xrdp_orders_state orders_state; + int rfx_min_pixel; }; #define PROTO_RDP_40 1 diff --git a/libxrdp/xrdp_orders.c b/libxrdp/xrdp_orders.c index 29234173..17e674af 100644 --- a/libxrdp/xrdp_orders.c +++ b/libxrdp/xrdp_orders.c @@ -47,6 +47,11 @@ xrdp_orders_create(struct xrdp_session *session, struct xrdp_rdp *rdp_layer) init_stream(self->out_s, 16384); self->orders_state.clip_right = 1; /* silly rdp right clip */ self->orders_state.clip_bottom = 1; /* silly rdp bottom clip */ + self->rfx_min_pixel = rdp_layer->client_info.rfx_min_pixel; + if (self->rfx_min_pixel == 0) + { + self->rfx_min_pixel = 64 * 32; + } return self; } @@ -2246,7 +2251,9 @@ xrdp_orders_send_as_rfx(struct xrdp_orders *self, return 0; } - if (width * height < 64) + LLOGLN(10, ("width %d height %d rfx_min_pixel %d", width, height, + self->rfx_min_pixel)); + if (width * height < self->rfx_min_pixel) { return 0; } diff --git a/libxrdp/xrdp_rdp.c b/libxrdp/xrdp_rdp.c index 93219968..cbf0fd12 100644 --- a/libxrdp/xrdp_rdp.c +++ b/libxrdp/xrdp_rdp.c @@ -131,6 +131,10 @@ xrdp_rdp_read_config(struct xrdp_client_info *client_info) { client_info->max_bpp = g_atoi(value); } + else if (g_strcasecmp(item, "rfx_min_pixel") == 0) + { + client_info->rfx_min_pixel = g_atoi(value); + } else if (g_strcasecmp(item, "new_cursors") == 0) { client_info->pointer_flags = text2bool(value) == 0 ? 2 : 0; @@ -947,16 +951,16 @@ xrdp_process_capset_bmpcache2(struct xrdp_rdp *self, struct stream *s, self->client_info.bitmap_cache_persist_enable = i; in_uint8s(s, 2); /* number of caches in set, 3 */ in_uint32_le(s, i); - i = MIN(i, 2000); + i = MIN(i, XRDP_BITMAP_CACHE_ENTRIES); self->client_info.cache1_entries = i; self->client_info.cache1_size = 256 * Bpp; in_uint32_le(s, i); - i = MIN(i, 2000); + i = MIN(i, XRDP_BITMAP_CACHE_ENTRIES); self->client_info.cache2_entries = i; self->client_info.cache2_size = 1024 * Bpp; in_uint32_le(s, i); i = i & 0x7fffffff; - i = MIN(i, 2000); + i = MIN(i, XRDP_BITMAP_CACHE_ENTRIES); self->client_info.cache3_entries = i; self->client_info.cache3_size = 4096 * Bpp; DEBUG(("cache1 entries %d size %d", self->client_info.cache1_entries, |
