2013-12-29 04:53:12 +00:00
|
|
|
/*
|
2016-03-25 19:59:40 +00:00
|
|
|
* Licensed to the Apache Software Foundation (ASF) under one
|
|
|
|
* or more contributor license agreements. See the NOTICE file
|
|
|
|
* distributed with this work for additional information
|
|
|
|
* regarding copyright ownership. The ASF licenses this file
|
|
|
|
* to you under the Apache License, Version 2.0 (the
|
|
|
|
* "License"); you may not use this file except in compliance
|
|
|
|
* with the License. You may obtain a copy of the License at
|
2012-01-04 03:09:33 +00:00
|
|
|
*
|
2016-03-25 19:59:40 +00:00
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
2012-01-04 03:09:33 +00:00
|
|
|
*
|
2016-03-25 19:59:40 +00:00
|
|
|
* Unless required by applicable law or agreed to in writing,
|
|
|
|
* software distributed under the License is distributed on an
|
|
|
|
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
|
|
* KIND, either express or implied. See the License for the
|
|
|
|
* specific language governing permissions and limitations
|
|
|
|
* under the License.
|
2013-12-29 04:53:12 +00:00
|
|
|
*/
|
|
|
|
|
2012-01-04 03:09:33 +00:00
|
|
|
|
|
|
|
#ifndef _GUAC_RDP_RDP_GDI_H
|
|
|
|
#define _GUAC_RDP_RDP_GDI_H
|
|
|
|
|
2014-01-01 22:44:28 +00:00
|
|
|
#include "config.h"
|
|
|
|
|
2012-01-04 03:09:33 +00:00
|
|
|
#include <freerdp/freerdp.h>
|
2014-01-01 22:44:28 +00:00
|
|
|
#include <guacamole/protocol.h>
|
2012-01-04 03:09:33 +00:00
|
|
|
|
2014-07-21 16:12:17 +00:00
|
|
|
/**
|
2016-03-01 05:50:00 +00:00
|
|
|
* Translates a standard RDP ROP3 value into a guac_composite_mode. Valid
|
|
|
|
* ROP3 operations indexes are listed in the RDP protocol specifications:
|
|
|
|
*
|
|
|
|
* http://msdn.microsoft.com/en-us/library/cc241583.aspx
|
|
|
|
*
|
2016-03-07 23:05:31 +00:00
|
|
|
* @param client
|
|
|
|
* The guac_client associated with the current RDP session.
|
|
|
|
*
|
|
|
|
* @param rop3
|
|
|
|
* The ROP3 operation index to translate.
|
2016-03-01 05:50:00 +00:00
|
|
|
*
|
|
|
|
* @return
|
|
|
|
* The guac_composite_mode that equates to, or most closely approximates,
|
|
|
|
* the given ROP3 operation.
|
2014-07-21 16:12:17 +00:00
|
|
|
*/
|
2016-03-01 05:50:00 +00:00
|
|
|
guac_composite_mode guac_rdp_rop3_transfer_function(guac_client* client,
|
|
|
|
int rop3);
|
2012-02-27 18:53:45 +00:00
|
|
|
|
2014-07-21 16:12:17 +00:00
|
|
|
/**
|
|
|
|
* Handler for RDP DSTBLT update.
|
2016-03-01 05:50:00 +00:00
|
|
|
*
|
2016-03-07 23:05:31 +00:00
|
|
|
* @param context
|
|
|
|
* The rdpContext associated with the current RDP session.
|
|
|
|
*
|
|
|
|
* @param dstblt
|
|
|
|
* The DSTBLT update to handle.
|
2014-07-21 16:12:17 +00:00
|
|
|
*/
|
2012-01-04 03:09:33 +00:00
|
|
|
void guac_rdp_gdi_dstblt(rdpContext* context, DSTBLT_ORDER* dstblt);
|
2014-07-21 16:12:17 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Handler for RDP PATBLT update.
|
2016-03-01 05:50:00 +00:00
|
|
|
*
|
2016-03-07 23:05:31 +00:00
|
|
|
* @param context
|
|
|
|
* The rdpContext associated with the current RDP session.
|
|
|
|
*
|
|
|
|
* @param patblt
|
|
|
|
* The PATBLT update to handle.
|
2014-07-21 16:12:17 +00:00
|
|
|
*/
|
2012-01-04 03:09:33 +00:00
|
|
|
void guac_rdp_gdi_patblt(rdpContext* context, PATBLT_ORDER* patblt);
|
2014-07-21 16:12:17 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Handler for RDP SCRBLT update.
|
2016-03-01 05:50:00 +00:00
|
|
|
*
|
2016-03-07 23:05:31 +00:00
|
|
|
* @param context
|
|
|
|
* The rdpContext associated with the current RDP session.
|
|
|
|
*
|
|
|
|
* @param scrblt
|
|
|
|
* The SCRBLT update to handle.
|
2014-07-21 16:12:17 +00:00
|
|
|
*/
|
2012-01-04 03:09:33 +00:00
|
|
|
void guac_rdp_gdi_scrblt(rdpContext* context, SCRBLT_ORDER* scrblt);
|
2014-07-21 16:12:17 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Handler for RDP MEMBLT update.
|
2016-03-01 05:50:00 +00:00
|
|
|
*
|
2016-03-07 23:05:31 +00:00
|
|
|
* @param context
|
|
|
|
* The rdpContext associated with the current RDP session.
|
|
|
|
*
|
|
|
|
* @param memblt
|
|
|
|
* The MEMBLT update to handle.
|
2014-07-21 16:12:17 +00:00
|
|
|
*/
|
2012-01-04 03:09:33 +00:00
|
|
|
void guac_rdp_gdi_memblt(rdpContext* context, MEMBLT_ORDER* memblt);
|
2014-07-21 16:12:17 +00:00
|
|
|
|
|
|
|
/**
|
2016-03-01 05:50:00 +00:00
|
|
|
* Handler for RDP OPAQUE RECT update.
|
|
|
|
*
|
2016-03-07 23:05:31 +00:00
|
|
|
* @param context
|
|
|
|
* The rdpContext associated with the current RDP session.
|
|
|
|
*
|
|
|
|
* @param opaque_rect
|
|
|
|
* The OPAQUE RECT update to handle.
|
2014-07-21 16:12:17 +00:00
|
|
|
*/
|
2016-03-01 05:50:00 +00:00
|
|
|
void guac_rdp_gdi_opaquerect(rdpContext* context,
|
|
|
|
OPAQUE_RECT_ORDER* opaque_rect);
|
2014-07-21 16:12:17 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Handler called when the remote color palette is changing.
|
2016-03-01 05:50:00 +00:00
|
|
|
*
|
2016-03-07 23:05:31 +00:00
|
|
|
* @param context
|
|
|
|
* The rdpContext associated with the current RDP session.
|
|
|
|
*
|
|
|
|
* @param palette
|
|
|
|
* The PALETTE update containing the new palette.
|
2014-07-21 16:12:17 +00:00
|
|
|
*/
|
2012-02-08 20:32:27 +00:00
|
|
|
void guac_rdp_gdi_palette_update(rdpContext* context, PALETTE_UPDATE* palette);
|
2014-07-21 16:12:17 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Handler called prior to calling the handlers for specific updates when
|
2016-03-01 05:50:00 +00:00
|
|
|
* those updates are clipped by a bounding rectangle. This is not a true RDP
|
|
|
|
* update, but is called by FreeRDP before and after any update involving
|
|
|
|
* clipping.
|
|
|
|
*
|
2016-03-07 23:05:31 +00:00
|
|
|
* @param context
|
|
|
|
* The rdpContext associated with the current RDP session.
|
2016-03-01 05:50:00 +00:00
|
|
|
*
|
|
|
|
* @param bounds
|
|
|
|
* The clipping rectangle to set, or NULL to remove any applied clipping
|
|
|
|
* rectangle.
|
2014-07-21 16:12:17 +00:00
|
|
|
*/
|
2012-02-08 22:16:05 +00:00
|
|
|
void guac_rdp_gdi_set_bounds(rdpContext* context, rdpBounds* bounds);
|
2014-07-21 16:12:17 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Handler called when a paint operation is complete. We don't actually
|
2016-03-01 05:50:00 +00:00
|
|
|
* use this, but FreeRDP requires it. Calling this function has no effect.
|
|
|
|
*
|
2016-03-07 23:05:31 +00:00
|
|
|
* @param context
|
|
|
|
* The rdpContext associated with the current RDP session.
|
2014-07-21 16:12:17 +00:00
|
|
|
*/
|
2012-04-04 00:58:31 +00:00
|
|
|
void guac_rdp_gdi_end_paint(rdpContext* context);
|
2012-01-04 03:09:33 +00:00
|
|
|
|
2014-07-21 16:12:17 +00:00
|
|
|
/**
|
|
|
|
* Handler called when the desktop dimensions change, either from a
|
|
|
|
* true desktop resize event received by the RDP client, or due to
|
|
|
|
* a revised size given by the server during initial connection
|
|
|
|
* negotiation.
|
2016-03-01 05:50:00 +00:00
|
|
|
*
|
|
|
|
* The new screen size will be made available within the settings associated
|
|
|
|
* with the given context.
|
|
|
|
*
|
2016-03-07 23:05:31 +00:00
|
|
|
* @param context
|
|
|
|
* The rdpContext associated with the current RDP session.
|
2014-07-21 16:12:17 +00:00
|
|
|
*/
|
|
|
|
void guac_rdp_gdi_desktop_resize(rdpContext* context);
|
|
|
|
|
2012-01-04 03:09:33 +00:00
|
|
|
#endif
|