From b372d63d78070e11da01add12a3d6680f0d5a068 Mon Sep 17 00:00:00 2001 From: Armin Novak Date: Tue, 4 Oct 2016 09:00:01 +0200 Subject: [PATCH] Reformatted file. --- include/freerdp/codec/region.h | 44 ++++++++++++++++++++-------------- 1 file changed, 26 insertions(+), 18 deletions(-) diff --git a/include/freerdp/codec/region.h b/include/freerdp/codec/region.h index 2a140bd77..5a6493505 100644 --- a/include/freerdp/codec/region.h +++ b/include/freerdp/codec/region.h @@ -37,9 +37,10 @@ typedef struct _REGION16_DATA REGION16_DATA; /** * @brief */ -struct _REGION16 { +struct _REGION16 +{ RECTANGLE_16 extents; - REGION16_DATA *data; + REGION16_DATA* data; }; typedef struct _REGION16 REGION16; @@ -48,14 +49,16 @@ typedef struct _REGION16 REGION16; * @param r2 second rectangle * @return if the two rectangles are equal */ -FREERDP_API BOOL rectangles_equal(const RECTANGLE_16 *r1, const RECTANGLE_16 *r2); +FREERDP_API BOOL rectangles_equal(const RECTANGLE_16* r1, + const RECTANGLE_16* r2); /** computes if two rectangles intersect * @param r1 first rectangle * @param r2 second rectangle * @return if the two rectangles intersect */ -FREERDP_API BOOL rectangles_intersects(const RECTANGLE_16 *r1, const RECTANGLE_16 *r2); +FREERDP_API BOOL rectangles_intersects(const RECTANGLE_16* r1, + const RECTANGLE_16* r2); /** computes the intersection of two rectangles * @param r1 first rectangle @@ -63,15 +66,16 @@ FREERDP_API BOOL rectangles_intersects(const RECTANGLE_16 *r1, const RECTANGLE_1 * @param dst resulting intersection * @return if the two rectangles intersect */ -FREERDP_API BOOL rectangles_intersection(const RECTANGLE_16 *r1, const RECTANGLE_16 *r2, RECTANGLE_16 *dst); +FREERDP_API BOOL rectangles_intersection(const RECTANGLE_16* r1, + const RECTANGLE_16* r2, RECTANGLE_16* dst); /** initialize a region16 * @param region the region to initialise */ -FREERDP_API void region16_init(REGION16 *region); +FREERDP_API void region16_init(REGION16* region); /** @return the number of rectangles of this region16 */ -FREERDP_API int region16_n_rects(const REGION16 *region); +FREERDP_API int region16_n_rects(const REGION16* region); /** returns a pointer to rectangles and the number of rectangles in this region. * nbRects can be set to NULL if not interested in the number of rectangles. @@ -79,39 +83,40 @@ FREERDP_API int region16_n_rects(const REGION16 *region); * @param nbRects if non-NULL returns the number of rectangles * @return a pointer on the rectangles */ -FREERDP_API const RECTANGLE_16 *region16_rects(const REGION16 *region, UINT32 *nbRects); +FREERDP_API const RECTANGLE_16* region16_rects(const REGION16* region, + UINT32* nbRects); /** @return the extents rectangle of this region */ -FREERDP_API const RECTANGLE_16 *region16_extents(const REGION16 *region); +FREERDP_API const RECTANGLE_16* region16_extents(const REGION16* region); /** returns if the rectangle is empty * @param rect * @return if the rectangle is empty */ -FREERDP_API BOOL rectangle_is_empty(const RECTANGLE_16 *rect); +FREERDP_API BOOL rectangle_is_empty(const RECTANGLE_16* rect); /** returns if the region is empty * @param region * @return if the region is empty */ -FREERDP_API BOOL region16_is_empty(const REGION16 *region); +FREERDP_API BOOL region16_is_empty(const REGION16* region); /** clears the region, the region is resetted to a (0,0,0,0) region * @param region */ -FREERDP_API void region16_clear(REGION16 *region); +FREERDP_API void region16_clear(REGION16* region); /** dumps the region on stderr * @param region the region to dump */ -FREERDP_API void region16_print(const REGION16 *region); +FREERDP_API void region16_print(const REGION16* region); /** copies the region to another region * @param dst destination region * @param src source region * @return if the operation was successful (false meaning out-of-memory) */ -FREERDP_API BOOL region16_copy(REGION16 *dst, const REGION16 *src); +FREERDP_API BOOL region16_copy(REGION16* dst, const REGION16* src); /** adds a rectangle in src and stores the resulting region in dst * @param dst destination region @@ -119,14 +124,16 @@ FREERDP_API BOOL region16_copy(REGION16 *dst, const REGION16 *src); * @param rect the rectangle to add * @return if the operation was successful (false meaning out-of-memory) */ -FREERDP_API BOOL region16_union_rect(REGION16 *dst, const REGION16 *src, const RECTANGLE_16 *rect); +FREERDP_API BOOL region16_union_rect(REGION16* dst, const REGION16* src, + const RECTANGLE_16* rect); /** returns if a rectangle intersects the region * @param src the region * @param arg2 the rectangle * @return if region and rectangle intersect */ -FREERDP_API BOOL region16_intersects_rect(const REGION16 *src, const RECTANGLE_16 *arg2); +FREERDP_API BOOL region16_intersects_rect(const REGION16* src, + const RECTANGLE_16* arg2); /** computes the intersection between a region and a rectangle * @param dst destination region @@ -134,12 +141,13 @@ FREERDP_API BOOL region16_intersects_rect(const REGION16 *src, const RECTANGLE_1 * @param arg2 the rectangle that intersects * @return if the operation was successful (false meaning out-of-memory) */ -FREERDP_API BOOL region16_intersect_rect(REGION16 *dst, const REGION16 *src, const RECTANGLE_16 *arg2); +FREERDP_API BOOL region16_intersect_rect(REGION16* dst, const REGION16* src, + const RECTANGLE_16* arg2); /** release internal data associated with this region * @param region the region to release */ -FREERDP_API void region16_uninit(REGION16 *region); +FREERDP_API void region16_uninit(REGION16* region); #ifdef __cplusplus }