createSurface.width = settings->DesktopWidth;
createSurface.height = settings->DesktopHeight;
- createSurface.pixelFormat = PIXEL_FORMAT_XRGB_8888;
+ createSurface.pixelFormat = GFX_PIXEL_FORMAT_XRGB_8888;
createSurface.surfaceId = 0;
surfaceToOutput.outputOriginX = 0;
surfaceToOutput.outputOriginY = 0;
surfaceToOutput.surfaceId = 0;
surfaceToOutput.reserved = 0;
-
- IFCALLRET(context->CreateSurface, error, context, &createSurface);
+
+ IFCALLRET(context->CreateSurface, error, context, &createSurface);
if (error)
{
WLog_ERR(TAG, "CreateSurface failed with error %lu", error);
return FALSE;
}
- IFCALLRET(context->MapSurfaceToOutput, error, context, &surfaceToOutput);
+ IFCALLRET(context->MapSurfaceToOutput, error, context, &surfaceToOutput);
if (error)
{
WLog_ERR(TAG, "MapSurfaceToOutput failed with error %lu", error);
screenRegion.bottom = settings->DesktopHeight;
region16_union_rect(&(client->invalidRegion),
- &(client->invalidRegion), &screenRegion);
+ &(client->invalidRegion), &screenRegion);
}
LeaveCriticalSection(&(client->lock));
if (!ret)
WLog_WARN(TAG, "subsystem->ClientCapabilities failed");
- /* Recalculate desktop size regardless whether previous call fail
- * or not. Make sure we send correct width/height to client */
+ /* Recalculate desktop size regardless whether previous call fail
+ * or not. Make sure we send correct width/height to client */
(void)shadow_client_recalc_desktop_size(client);
return ret;
settings->NSCodec = FALSE; /* NSCodec compressor does not support fragmentation yet */
WLog_INFO(TAG, "Client from %s is activated (%dx%d@%d)",
- peer->hostname, settings->DesktopWidth,
- settings->DesktopHeight, settings->ColorDepth);
+ peer->hostname, settings->DesktopWidth,
+ settings->DesktopHeight, settings->ColorDepth);
/* Resize client if necessary */
if (shadow_client_recalc_desktop_size(client))
{
peer->update->DesktopResize(peer->update->context);
WLog_INFO(TAG, "Client from %s is resized (%dx%d@%d)",
- peer->hostname, settings->DesktopWidth,
- settings->DesktopHeight, settings->ColorDepth);
+ peer->hostname, settings->DesktopWidth,
+ settings->DesktopHeight, settings->ColorDepth);
}
if (shadow_client_channels_post_connect(client) != CHANNEL_RC_OK)
static UINT shadow_client_rdpgfx_frame_acknowledge(RdpgfxServerContext* context, RDPGFX_FRAME_ACKNOWLEDGE_PDU* frameAcknowledge)
{
- shadow_client_common_frame_acknowledge((rdpShadowClient *)context->custom,
- frameAcknowledge->frameId);
+ shadow_client_common_frame_acknowledge((rdpShadowClient *)context->custom,
+ frameAcknowledge->frameId);
return CHANNEL_RC_OK;
}
static UINT shadow_client_rdpgfx_qoe_frame_acknowledge(RdpgfxServerContext* context, RDPGFX_QOE_FRAME_ACKNOWLEDGE_PDU* qoeFrameAcknowledge)
{
- shadow_client_common_frame_acknowledge((rdpShadowClient *)context->custom,
- qoeFrameAcknowledge->frameId);
+ shadow_client_common_frame_acknowledge((rdpShadowClient *)context->custom,
+ qoeFrameAcknowledge->frameId);
return CHANNEL_RC_OK;
}
*
* @return TRUE on success
*/
-static BOOL shadow_client_send_surface_gfx(rdpShadowClient* client,
+static BOOL shadow_client_send_surface_gfx(rdpShadowClient* client,
BYTE* pSrcData, int nSrcStep, int nXSrc, int nYSrc, int nWidth, int nHeight)
{
UINT error = CHANNEL_RC_OK;
cmdstart.frameId = shadow_encoder_create_frame_id(encoder);
GetSystemTime(&sTime);
- cmdstart.timestamp = sTime.wHour << 22 | sTime.wMinute << 16 |
- sTime.wSecond << 10 | sTime.wMilliseconds;
+ cmdstart.timestamp = sTime.wHour << 22 | sTime.wMinute << 16 |
+ sTime.wSecond << 10 | sTime.wMilliseconds;
cmdend.frameId = cmdstart.frameId;
cmd.surfaceId = 0;
cmd.contextId = 0;
- cmd.format = PIXEL_FORMAT_XRGB_8888;
+ cmd.format = PIXEL_FORMAT_XRGB32;
cmd.left = nXSrc;
cmd.top = nYSrc;
cmd.right = cmd.left + nWidth;
return FALSE;
}
- avc420_compress(encoder->h264, pSrcData, PIXEL_FORMAT_RGB32, nSrcStep,
- nWidth, nHeight, &avc420.data, &avc420.length);
+ avc420_compress(encoder->h264, pSrcData, PIXEL_FORMAT_XRGB32, nSrcStep,
+ nWidth, nHeight, &avc420.data, &avc420.length);
cmd.codecId = RDPGFX_CODECID_AVC420;
cmd.extra = (void *)&avc420;
*
* @return TRUE on success
*/
-static BOOL shadow_client_send_surface_bits(rdpShadowClient* client,
+static BOOL shadow_client_send_surface_bits(rdpShadowClient* client,
BYTE* pSrcData, int nSrcStep, int nXSrc, int nYSrc, int nWidth, int nHeight)
{
BOOL ret = TRUE;
*
* @return TRUE on success
*/
-static BOOL shadow_client_send_bitmap_update(rdpShadowClient* client,
+static BOOL shadow_client_send_bitmap_update(rdpShadowClient* client,
BYTE* pSrcData, int nSrcStep, int nXSrc, int nYSrc, int nWidth, int nHeight)
{
BOOL ret = TRUE;
}
}
- SrcFormat = PIXEL_FORMAT_RGB32;
+ SrcFormat = PIXEL_FORMAT_XRGB32;
if ((nXSrc % 4) != 0)
{
}
else
{
- int dstSize;
+ UINT32 dstSize;
buffer = encoder->grid[k];
data = &pSrcData[(bitmap->destTop * nSrcStep) + (bitmap->destLeft * 4)];
if (updateSizeEstimate > maxUpdateSize)
{
- INT32 i, j;
+ UINT32 i, j;
UINT32 updateSize;
UINT32 newUpdateSize;
BITMAP_DATA* fragBitmapData = NULL;
BYTE* pSrcData;
int nSrcStep;
int index;
- int numRects = 0;
+ UINT32 numRects = 0;
const RECTANGLE_16* rects;
context = (rdpContext*) client;
//WLog_INFO(TAG, "shadow_client_send_surface_update: x: %d y: %d width: %d height: %d right: %d bottom: %d",
// nXSrc, nYSrc, nWidth, nHeight, nXSrc + nWidth, nYSrc + nHeight);
- if (settings->SupportGraphicsPipeline &&
+ if (settings->SupportGraphicsPipeline &&
settings->GfxH264 &&
pStatus->gfxOpened)
{
*/
BOOL shadow_client_surface_update(rdpShadowClient* client, REGION16* region)
{
- int numRects = 0;
+ UINT32 numRects = 0;
const RECTANGLE_16* rects;
rects = region16_rects(region, &numRects);
}
/*
- * The return value of shadow_multiclient_consume is whether or not
+ * The return value of shadow_multiclient_consume is whether or not
* the subscriber really consumes the event. It's not cared currently.
*/
(void)shadow_multiclient_consume(UpdateSubscriber);