Add cache and bitmap decompress stub.
This commit is contained in:
parent
b138d3bfbc
commit
d3302341e7
@ -46,6 +46,7 @@ AC_PROG_LIBTOOL
|
|||||||
# Checks for libraries.
|
# Checks for libraries.
|
||||||
AC_CHECK_LIB([guac], [guac_client_plugin_open],, AC_MSG_ERROR("libguac must be installed first"))
|
AC_CHECK_LIB([guac], [guac_client_plugin_open],, AC_MSG_ERROR("libguac must be installed first"))
|
||||||
AC_CHECK_LIB([cairo], [cairo_create],, AC_MSG_ERROR("cairo is required for drawing instructions"))
|
AC_CHECK_LIB([cairo], [cairo_create],, AC_MSG_ERROR("cairo is required for drawing instructions"))
|
||||||
|
AC_CHECK_LIB([freerdp-cache], [glyph_cache_register_callbacks],, AC_MSG_ERROR("libfreerdp-cache is required (part of FreeRDP)"))
|
||||||
AC_CHECK_LIB([freerdp-core], [freerdp_new],, AC_MSG_ERROR("libfreerdp-core is required (part of FreeRDP)"))
|
AC_CHECK_LIB([freerdp-core], [freerdp_new],, AC_MSG_ERROR("libfreerdp-core is required (part of FreeRDP)"))
|
||||||
AC_CHECK_LIB([freerdp-channels], [freerdp_channels_new],, AC_MSG_ERROR("libfreerdp-channels is required (part of FreeRDP)"))
|
AC_CHECK_LIB([freerdp-channels], [freerdp_channels_new],, AC_MSG_ERROR("libfreerdp-channels is required (part of FreeRDP)"))
|
||||||
AC_CHECK_LIB([freerdp-utils], [xzalloc],, AC_MSG_ERROR("libfreerdp-utils is required (part of FreeRDP)"))
|
AC_CHECK_LIB([freerdp-utils], [xzalloc],, AC_MSG_ERROR("libfreerdp-utils is required (part of FreeRDP)"))
|
||||||
|
@ -57,6 +57,7 @@ typedef struct guac_rdp_bitmap {
|
|||||||
} guac_rdp_bitmap;
|
} guac_rdp_bitmap;
|
||||||
|
|
||||||
void guac_rdp_bitmap_new(rdpContext* context, rdpBitmap* bitmap);
|
void guac_rdp_bitmap_new(rdpContext* context, rdpBitmap* bitmap);
|
||||||
|
void guac_rdp_bitmap_decompress(rdpContext* context, rdpBitmap* bitmap, uint8* data, int width, int height, int bpp, int length, boolean compressed);
|
||||||
void guac_rdp_bitmap_paint(rdpContext* context, rdpBitmap* bitmap);
|
void guac_rdp_bitmap_paint(rdpContext* context, rdpBitmap* bitmap);
|
||||||
void guac_rdp_bitmap_free(rdpContext* context, rdpBitmap* bitmap);
|
void guac_rdp_bitmap_free(rdpContext* context, rdpBitmap* bitmap);
|
||||||
void guac_rdp_bitmap_setsurface(rdpContext* context, rdpBitmap* bitmap, boolean primary);
|
void guac_rdp_bitmap_setsurface(rdpContext* context, rdpBitmap* bitmap, boolean primary);
|
||||||
|
@ -44,6 +44,11 @@
|
|||||||
#include <freerdp/freerdp.h>
|
#include <freerdp/freerdp.h>
|
||||||
#include <freerdp/utils/memory.h>
|
#include <freerdp/utils/memory.h>
|
||||||
#include <freerdp/cache/bitmap.h>
|
#include <freerdp/cache/bitmap.h>
|
||||||
|
#include <freerdp/cache/brush.h>
|
||||||
|
#include <freerdp/cache/glyph.h>
|
||||||
|
#include <freerdp/cache/palette.h>
|
||||||
|
#include <freerdp/cache/pointer.h>
|
||||||
|
#include <freerdp/cache/offscreen.h>
|
||||||
#include <freerdp/channels/channels.h>
|
#include <freerdp/channels/channels.h>
|
||||||
#include <freerdp/input.h>
|
#include <freerdp/input.h>
|
||||||
#include <freerdp/constants.h>
|
#include <freerdp/constants.h>
|
||||||
@ -84,13 +89,16 @@ boolean rdp_freerdp_pre_connect(freerdp* instance) {
|
|||||||
rdpPointer* pointer;
|
rdpPointer* pointer;
|
||||||
rdpPrimaryUpdate* primary;
|
rdpPrimaryUpdate* primary;
|
||||||
|
|
||||||
|
/* Init FreeRDP cache */
|
||||||
|
instance->context->cache = cache_new(instance->settings);
|
||||||
|
|
||||||
/* Set up bitmap handling */
|
/* Set up bitmap handling */
|
||||||
bitmap = xnew(rdpBitmap);
|
bitmap = xnew(rdpBitmap);
|
||||||
bitmap->size = sizeof(guac_rdp_bitmap);
|
bitmap->size = sizeof(guac_rdp_bitmap);
|
||||||
bitmap->New = guac_rdp_bitmap_new;
|
bitmap->New = guac_rdp_bitmap_new;
|
||||||
bitmap->Free = guac_rdp_bitmap_free;
|
bitmap->Free = guac_rdp_bitmap_free;
|
||||||
bitmap->Paint = guac_rdp_bitmap_paint;
|
bitmap->Paint = guac_rdp_bitmap_paint;
|
||||||
/* bitmap->Decompress = guac_rdp_bitmap_decompress; */
|
bitmap->Decompress = guac_rdp_bitmap_decompress;
|
||||||
bitmap->SetSurface = guac_rdp_bitmap_setsurface;
|
bitmap->SetSurface = guac_rdp_bitmap_setsurface;
|
||||||
graphics_register_bitmap(context->graphics, bitmap);
|
graphics_register_bitmap(context->graphics, bitmap);
|
||||||
|
|
||||||
@ -119,6 +127,13 @@ boolean rdp_freerdp_pre_connect(freerdp* instance) {
|
|||||||
primary->MemBlt = guac_rdp_gdi_memblt;
|
primary->MemBlt = guac_rdp_gdi_memblt;
|
||||||
primary->OpaqueRect = guac_rdp_gdi_opaquerect;
|
primary->OpaqueRect = guac_rdp_gdi_opaquerect;
|
||||||
|
|
||||||
|
/*pointer_cache_register_callbacks(instance->update);*/
|
||||||
|
glyph_cache_register_callbacks(instance->update);
|
||||||
|
/*brush_cache_register_callbacks(instance->update);*/
|
||||||
|
bitmap_cache_register_callbacks(instance->update);
|
||||||
|
/*offscreen_cache_register_callbacks(instance->update);*/
|
||||||
|
/*palette_cache_register_callbacks(instance->update);*/
|
||||||
|
|
||||||
/* Init channels (pre-connect) */
|
/* Init channels (pre-connect) */
|
||||||
if (freerdp_channels_pre_connect(channels, instance)) {
|
if (freerdp_channels_pre_connect(channels, instance)) {
|
||||||
guac_protocol_send_error(client->socket, "Error initializing RDP client channel manager");
|
guac_protocol_send_error(client->socket, "Error initializing RDP client channel manager");
|
||||||
|
@ -119,3 +119,8 @@ void guac_rdp_bitmap_setsurface(rdpContext* context, rdpBitmap* bitmap, boolean
|
|||||||
guac_client_log_info(client, "guac_rdp_bitmap_setsurface()");
|
guac_client_log_info(client, "guac_rdp_bitmap_setsurface()");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void guac_rdp_bitmap_decompress(rdpContext* context, rdpBitmap* bitmap, uint8* data, int width, int height, int bpp, int length, boolean compressed) {
|
||||||
|
guac_client* client = ((rdp_freerdp_context*) context)->client;
|
||||||
|
guac_client_log_info(client, "guac_rdp_bitmap_decompress()");
|
||||||
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user