don't jpeg compress fonts

master
Jay Sorg 13 years ago
parent d61f32865d
commit e09f14e6d4

@ -635,11 +635,11 @@ libxrdp_orders_send_raw_bitmap2(struct xrdp_session* session,
int EXPORT_CC int EXPORT_CC
libxrdp_orders_send_bitmap2(struct xrdp_session* session, libxrdp_orders_send_bitmap2(struct xrdp_session* session,
int width, int height, int bpp, char* data, int width, int height, int bpp, char* data,
int cache_id, int cache_idx) int cache_id, int cache_idx, int hints)
{ {
return xrdp_orders_send_bitmap2((struct xrdp_orders*)session->orders, return xrdp_orders_send_bitmap2((struct xrdp_orders*)session->orders,
width, height, bpp, data, width, height, bpp, data,
cache_id, cache_idx); cache_id, cache_idx, hints);
} }
/*****************************************************************************/ /*****************************************************************************/

@ -383,7 +383,7 @@ xrdp_orders_send_raw_bitmap2(struct xrdp_orders* self,
int APP_CC int APP_CC
xrdp_orders_send_bitmap2(struct xrdp_orders* self, xrdp_orders_send_bitmap2(struct xrdp_orders* self,
int width, int height, int bpp, char* data, int width, int height, int bpp, char* data,
int cache_id, int cache_idx); int cache_id, int cache_idx, int hints);
int APP_CC int APP_CC
xrdp_orders_send_brush(struct xrdp_orders* self, int width, int height, xrdp_orders_send_brush(struct xrdp_orders* self, int width, int height,
int bpp, int type, int size, char* data, int cache_id); int bpp, int type, int size, char* data, int cache_id);

@ -162,7 +162,7 @@ libxrdp_orders_send_raw_bitmap2(struct xrdp_session* session,
int DEFAULT_CC int DEFAULT_CC
libxrdp_orders_send_bitmap2(struct xrdp_session* session, libxrdp_orders_send_bitmap2(struct xrdp_session* session,
int width, int height, int bpp, char* data, int width, int height, int bpp, char* data,
int cache_id, int cache_idx); int cache_id, int cache_idx, int hints);
int DEFAULT_CC int DEFAULT_CC
libxrdp_query_channel(struct xrdp_session* session, int index, libxrdp_query_channel(struct xrdp_session* session, int index,
char* channel_name, int* channel_flags); char* channel_name, int* channel_flags);

@ -1831,8 +1831,12 @@ xrdp_orders_send_raw_bitmap2(struct xrdp_orders* self,
/*****************************************************************************/ /*****************************************************************************/
static int static int
xrdp_orders_send_as_jpeg(struct xrdp_orders* self, xrdp_orders_send_as_jpeg(struct xrdp_orders* self,
int width, int height, int bpp) int width, int height, int bpp, int hints)
{ {
if (hints & 1)
{
return 0;
}
if (bpp != 24) if (bpp != 24)
{ {
return 0; return 0;
@ -1854,7 +1858,7 @@ xrdp_orders_send_as_jpeg(struct xrdp_orders* self,
int APP_CC int APP_CC
xrdp_orders_send_bitmap2(struct xrdp_orders* self, xrdp_orders_send_bitmap2(struct xrdp_orders* self,
int width, int height, int bpp, char* data, int width, int height, int bpp, char* data,
int cache_id, int cache_idx) int cache_id, int cache_idx, int hints)
{ {
int order_flags = 0; int order_flags = 0;
int len = 0; int len = 0;
@ -1890,7 +1894,7 @@ xrdp_orders_send_bitmap2(struct xrdp_orders* self,
p = s->p; p = s->p;
i = height; i = height;
is_jpeg = 0; is_jpeg = 0;
if (xrdp_orders_send_as_jpeg(self, width, height, bpp)) if (xrdp_orders_send_as_jpeg(self, width, height, bpp, hints))
{ {
lines_sending = xrdp_jpeg_compress(data, width, height, s, bpp, 16384, lines_sending = xrdp_jpeg_compress(data, width, height, s, bpp, 16384,
i - 1, temp_s, e); i - 1, temp_s, e);

@ -280,7 +280,8 @@ xrdp_cache_add_bitmap(struct xrdp_cache* self, struct xrdp_bitmap* bitmap,
{ {
libxrdp_orders_send_bitmap2(self->session, bitmap->width, libxrdp_orders_send_bitmap2(self->session, bitmap->width,
bitmap->height, bitmap->bpp, bitmap->height, bitmap->bpp,
bitmap->data, cache_id, cache_idx); bitmap->data, cache_id, cache_idx,
hints);
} }
else else
{ {

Loading…
Cancel
Save