summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJay Sorg <jay.sorg@gmail.com>2014-03-16 15:54:13 -0700
committerJay Sorg <jay.sorg@gmail.com>2014-03-16 15:54:13 -0700
commit9414467af284458b6835fd4866bf847cad1b1f66 (patch)
tree4f2d956d4d97935f28b2e0568735fbedb62b17d6
parent5fe484012f6dd569f7d190c16fd447d4bdaa5861 (diff)
downloadxrdp-proprietary-9414467af284458b6835fd4866bf847cad1b1f66.tar.gz
xrdp-proprietary-9414467af284458b6835fd4866bf847cad1b1f66.zip
libxrdp: export jpeg compress for codec mode
-rw-r--r--libxrdp/libxrdp.c19
-rw-r--r--libxrdp/libxrdpinc.h7
2 files changed, 26 insertions, 0 deletions
diff --git a/libxrdp/libxrdp.c b/libxrdp/libxrdp.c
index c00f99d7..24443429 100644
--- a/libxrdp/libxrdp.c
+++ b/libxrdp/libxrdp.c
@@ -1290,3 +1290,22 @@ libxrdp_monitored_desktop(struct xrdp_session *session,
orders = (struct xrdp_orders *)(session->orders);
return xrdp_orders_send_monitored_desktop(orders, mdo, flags);
}
+
+/*****************************************************************************/
+int EXPORT_CC
+libxrdp_codec_jpeg_compress(struct xrdp_session *session,
+ int format, char *inp_data,
+ int width, int height,
+ int stride, int x, int y,
+ int cx, int cy, int quality,
+ char *out_data, int *io_len)
+{
+ struct xrdp_orders *orders;
+ void* jpeg_han;
+
+ orders = (struct xrdp_orders *)(session->orders);
+ jpeg_han = orders->jpeg_han;
+ return xrdp_codec_jpeg_compress(jpeg_han, format, inp_data,
+ width, height, stride, x, y,
+ cx, cy, quality, out_data, io_len);
+}
diff --git a/libxrdp/libxrdpinc.h b/libxrdp/libxrdpinc.h
index 58ba5093..8e41e7fe 100644
--- a/libxrdp/libxrdpinc.h
+++ b/libxrdp/libxrdpinc.h
@@ -228,5 +228,12 @@ int DEFAULT_CC
libxrdp_monitored_desktop(struct xrdp_session* session,
struct rail_monitored_desktop_order* mdo,
int flags);
+int DEFAULT_CC
+libxrdp_codec_jpeg_compress(struct xrdp_session *session,
+ int format, char *inp_data,
+ int width, int height,
+ int stride, int x, int y,
+ int cx, int cy, int quality,
+ char *out_data, int *io_len);
#endif