diff --git a/channels/rdpgfx/client/rdpgfx_codec.c b/channels/rdpgfx/client/rdpgfx_codec.c index 3eba6c363..c7941ab0f 100644 --- a/channels/rdpgfx/client/rdpgfx_codec.c +++ b/channels/rdpgfx/client/rdpgfx_codec.c @@ -41,7 +41,7 @@ static UINT rdpgfx_read_h264_metablock(RDPGFX_PLUGIN* gfx, wStream* s, RDPGFX_H264_METABLOCK* meta) { UINT32 index; - RDPGFX_RECT16* regionRect; + RECTANGLE_16* regionRect; RDPGFX_H264_QUANT_QUALITY* quantQualityVal; UINT error = ERROR_INVALID_DATA; @@ -62,7 +62,7 @@ static UINT rdpgfx_read_h264_metablock(RDPGFX_PLUGIN* gfx, wStream* s, RDPGFX_H2 goto error_out; } - meta->regionRects = (RDPGFX_RECT16*) malloc(meta->numRegionRects * sizeof(RDPGFX_RECT16)); + meta->regionRects = (RECTANGLE_16*) malloc(meta->numRegionRects * sizeof(RECTANGLE_16)); if (!meta->regionRects) { diff --git a/channels/rdpgfx/client/rdpgfx_common.c b/channels/rdpgfx/client/rdpgfx_common.c index 8b6e07389..2c7c1771f 100644 --- a/channels/rdpgfx/client/rdpgfx_common.c +++ b/channels/rdpgfx/client/rdpgfx_common.c @@ -161,7 +161,7 @@ UINT rdpgfx_write_point16(wStream* s, RDPGFX_POINT16* point16) * * @return 0 on success, otherwise a Win32 error code */ -UINT rdpgfx_read_rect16(wStream* s, RDPGFX_RECT16* rect16) +UINT rdpgfx_read_rect16(wStream* s, RECTANGLE_16* rect16) { if (Stream_GetRemainingLength(s) < 8) { @@ -182,7 +182,7 @@ UINT rdpgfx_read_rect16(wStream* s, RDPGFX_RECT16* rect16) * * @return 0 on success, otherwise a Win32 error code */ -UINT rdpgfx_write_rect16(wStream* s, RDPGFX_RECT16* rect16) +UINT rdpgfx_write_rect16(wStream* s, RECTANGLE_16* rect16) { Stream_Write_UINT16(s, rect16->left); /* left (2 bytes) */ Stream_Write_UINT16(s, rect16->top); /* top (2 bytes) */ diff --git a/channels/rdpgfx/client/rdpgfx_common.h b/channels/rdpgfx/client/rdpgfx_common.h index 188102cd8..9d082056d 100644 --- a/channels/rdpgfx/client/rdpgfx_common.h +++ b/channels/rdpgfx/client/rdpgfx_common.h @@ -36,8 +36,8 @@ UINT rdpgfx_write_header(wStream* s, RDPGFX_HEADER* header); UINT rdpgfx_read_point16(wStream* s, RDPGFX_POINT16* pt16); UINT rdpgfx_write_point16(wStream* s, RDPGFX_POINT16* point16); -UINT rdpgfx_read_rect16(wStream* s, RDPGFX_RECT16* rect16); -UINT rdpgfx_write_rect16(wStream* s, RDPGFX_RECT16* rect16); +UINT rdpgfx_read_rect16(wStream* s, RECTANGLE_16* rect16); +UINT rdpgfx_write_rect16(wStream* s, RECTANGLE_16* rect16); UINT rdpgfx_read_color32(wStream* s, RDPGFX_COLOR32* color32); UINT rdpgfx_write_color32(wStream* s, RDPGFX_COLOR32* color32); diff --git a/channels/rdpgfx/client/rdpgfx_main.c b/channels/rdpgfx/client/rdpgfx_main.c index 07ec66cc5..0c627da8d 100644 --- a/channels/rdpgfx/client/rdpgfx_main.c +++ b/channels/rdpgfx/client/rdpgfx_main.c @@ -688,7 +688,7 @@ static UINT rdpgfx_recv_delete_encoding_context_pdu(RDPGFX_CHANNEL_CALLBACK* cal UINT rdpgfx_recv_solid_fill_pdu(RDPGFX_CHANNEL_CALLBACK* callback, wStream* s) { UINT16 index; - RDPGFX_RECT16* fillRect; + RECTANGLE_16* fillRect; RDPGFX_SOLID_FILL_PDU pdu; RDPGFX_PLUGIN* gfx = (RDPGFX_PLUGIN*) callback->plugin; RdpgfxClientContext* context = (RdpgfxClientContext*) gfx->iface.pInterface; @@ -714,7 +714,7 @@ UINT rdpgfx_recv_solid_fill_pdu(RDPGFX_CHANNEL_CALLBACK* callback, wStream* s) return ERROR_INVALID_DATA; } - pdu.fillRects = (RDPGFX_RECT16*) calloc(pdu.fillRectCount, sizeof(RDPGFX_RECT16)); + pdu.fillRects = (RECTANGLE_16*) calloc(pdu.fillRectCount, sizeof(RECTANGLE_16)); if (!pdu.fillRects) { diff --git a/client/X11/xf_gfx.c b/client/X11/xf_gfx.c index d87e79cdb..3167ac9cd 100644 --- a/client/X11/xf_gfx.c +++ b/client/X11/xf_gfx.c @@ -833,7 +833,7 @@ UINT xf_SolidFill(RdpgfxClientContext* context, RDPGFX_SOLID_FILL_PDU* solidFill UINT32 color; BYTE a, r, g, b; int nWidth, nHeight; - RDPGFX_RECT16* rect; + RECTANGLE_16* rect; xfGfxSurface* surface; RECTANGLE_16 invalidRect; xfContext* xfc = (xfContext*) context->custom; @@ -884,7 +884,7 @@ UINT xf_SurfaceToSurface(RdpgfxClientContext* context, RDPGFX_SURFACE_TO_SURFACE UINT16 index; BOOL sameSurface; int nWidth, nHeight; - RDPGFX_RECT16* rectSrc; + RECTANGLE_16* rectSrc; RDPGFX_POINT16* destPt; RECTANGLE_16 invalidRect; xfGfxSurface* surfaceSrc; @@ -947,7 +947,7 @@ UINT xf_SurfaceToSurface(RdpgfxClientContext* context, RDPGFX_SURFACE_TO_SURFACE UINT xf_SurfaceToCache(RdpgfxClientContext* context, RDPGFX_SURFACE_TO_CACHE_PDU* surfaceToCache) { size_t size; - RDPGFX_RECT16* rect; + RECTANGLE_16* rect; xfGfxSurface* surface; xfGfxCacheEntry* cacheEntry; xfContext* xfc = (xfContext*) context->custom; diff --git a/include/freerdp/channels/rdpgfx.h b/include/freerdp/channels/rdpgfx.h index 24943ff5f..57a0d3dcb 100644 --- a/include/freerdp/channels/rdpgfx.h +++ b/include/freerdp/channels/rdpgfx.h @@ -37,15 +37,6 @@ struct _RDPGFX_POINT16 }; typedef struct _RDPGFX_POINT16 RDPGFX_POINT16; -struct _RDPGFX_RECT16 -{ - UINT16 left; - UINT16 top; - UINT16 right; - UINT16 bottom; -}; -typedef struct _RDPGFX_RECT16 RDPGFX_RECT16; - struct _RDPGFX_COLOR32 { BYTE B; @@ -145,7 +136,7 @@ struct _RDPGFX_WIRE_TO_SURFACE_PDU_1 UINT16 surfaceId; UINT16 codecId; RDPGFX_PIXELFORMAT pixelFormat; - RDPGFX_RECT16 destRect; + RECTANGLE_16 destRect; UINT32 bitmapDataLength; BYTE* bitmapData; }; @@ -195,7 +186,7 @@ struct _RDPGFX_SOLID_FILL_PDU UINT16 surfaceId; RDPGFX_COLOR32 fillPixel; UINT16 fillRectCount; - RDPGFX_RECT16* fillRects; + RECTANGLE_16* fillRects; }; typedef struct _RDPGFX_SOLID_FILL_PDU RDPGFX_SOLID_FILL_PDU; @@ -203,7 +194,7 @@ struct _RDPGFX_SURFACE_TO_SURFACE_PDU { UINT16 surfaceIdSrc; UINT16 surfaceIdDest; - RDPGFX_RECT16 rectSrc; + RECTANGLE_16 rectSrc; UINT16 destPtsCount; RDPGFX_POINT16* destPts; }; @@ -214,7 +205,7 @@ struct _RDPGFX_SURFACE_TO_CACHE_PDU UINT16 surfaceId; UINT64 cacheKey; UINT16 cacheSlot; - RDPGFX_RECT16 rectSrc; + RECTANGLE_16 rectSrc; }; typedef struct _RDPGFX_SURFACE_TO_CACHE_PDU RDPGFX_SURFACE_TO_CACHE_PDU; @@ -349,7 +340,7 @@ typedef struct _RDPGFX_H264_QUANT_QUALITY RDPGFX_H264_QUANT_QUALITY; struct _RDPGFX_H264_METABLOCK { UINT32 numRegionRects; - RDPGFX_RECT16* regionRects; + RECTANGLE_16* regionRects; RDPGFX_H264_QUANT_QUALITY* quantQualityVals; }; typedef struct _RDPGFX_H264_METABLOCK RDPGFX_H264_METABLOCK; diff --git a/include/freerdp/codec/h264.h b/include/freerdp/codec/h264.h index 86e2a2c2c..37d88c55f 100644 --- a/include/freerdp/codec/h264.h +++ b/include/freerdp/codec/h264.h @@ -78,7 +78,7 @@ FREERDP_API int h264_compress(H264_CONTEXT* h264, BYTE* pSrcData, DWORD SrcForma FREERDP_API int h264_decompress(H264_CONTEXT* h264, BYTE* pSrcData, UINT32 SrcSize, BYTE** ppDstData, DWORD DstFormat, int nDstStep, int nDstWidth, int nDstHeight, - RDPGFX_RECT16* regionRects, int numRegionRect); + RECTANGLE_16* regionRects, int numRegionRect); FREERDP_API BOOL h264_context_reset(H264_CONTEXT* h264, UINT32 width, UINT32 height); diff --git a/libfreerdp/codec/h264.c b/libfreerdp/codec/h264.c index 230b3ab11..1aba3cd66 100644 --- a/libfreerdp/codec/h264.c +++ b/libfreerdp/codec/h264.c @@ -1353,7 +1353,7 @@ static H264_CONTEXT_SUBSYSTEM g_Subsystem_libavcodec = int h264_decompress(H264_CONTEXT* h264, BYTE* pSrcData, UINT32 SrcSize, BYTE** ppDstData, DWORD DstFormat, int nDstStep, int nDstWidth, - int nDstHeight, RDPGFX_RECT16* regionRects, int numRegionRects) + int nDstHeight, RECTANGLE_16* regionRects, int numRegionRects) { int index; int status; @@ -1364,7 +1364,7 @@ int h264_decompress(H264_CONTEXT* h264, BYTE* pSrcData, UINT32 SrcSize, BYTE** pYUVData; int width, height; BYTE* pYUVPoint[3]; - RDPGFX_RECT16* rect; + RECTANGLE_16* rect; primitives_t* prims = primitives_get(); if (!h264) diff --git a/libfreerdp/gdi/gfx.c b/libfreerdp/gdi/gfx.c index 523734038..3a3fde1bc 100644 --- a/libfreerdp/gdi/gfx.c +++ b/libfreerdp/gdi/gfx.c @@ -807,7 +807,7 @@ UINT gdi_SolidFill(RdpgfxClientContext* context, RDPGFX_SOLID_FILL_PDU* solidFil UINT32 color; BYTE a, r, g, b; int nWidth, nHeight; - RDPGFX_RECT16* rect; + RECTANGLE_16* rect; gdiGfxSurface* surface; RECTANGLE_16 invalidRect; rdpGdi* gdi = (rdpGdi*) context->custom; @@ -861,7 +861,7 @@ UINT gdi_SurfaceToSurface(RdpgfxClientContext* context, RDPGFX_SURFACE_TO_SURFAC UINT16 index; BOOL sameSurface; int nWidth, nHeight; - RDPGFX_RECT16* rectSrc; + RECTANGLE_16* rectSrc; RDPGFX_POINT16* destPt; RECTANGLE_16 invalidRect; gdiGfxSurface* surfaceSrc; @@ -922,7 +922,7 @@ UINT gdi_SurfaceToSurface(RdpgfxClientContext* context, RDPGFX_SURFACE_TO_SURFAC */ UINT gdi_SurfaceToCache(RdpgfxClientContext* context, RDPGFX_SURFACE_TO_CACHE_PDU* surfaceToCache) { - RDPGFX_RECT16* rect; + RECTANGLE_16* rect; gdiGfxSurface* surface; gdiGfxCacheEntry* cacheEntry; rdpGdi* gdi = (rdpGdi*) context->custom;