MPLABĀ® Harmony Graphics Suite
GFX v3.13.0
Legato API Documentation
|
Rectangle functions and definitions. More...
#include "gfx/legato/common/legato_common.h"
Go to the source code of this file.
Functions | |
leBool | leRectContainsPoint (const leRect *rect, const lePoint *point) |
Determines if a point is inside a rectangle. More... | |
leBool | leRectContainsRect (const leRect *l_rect, const leRect *r_rect) |
Determines if a rectangle is completely inside another rectangle. More... | |
leBool | leRectIntersects (const leRect *l_rect, const leRect *r_rect) |
Determines if two rectangles are intersecting. More... | |
void | leRectCombine (const leRect *l_rect, const leRect *r_rect, leRect *res) |
Combine rectangles. More... | |
void | leRectClip (const leRect *l_rect, const leRect *r_rect, leRect *result) |
Clips a rectangle to the space of another rectangle. More... | |
void | leRectClipAdj (const leRect *l_rect, const leRect *r_rect, leRect *adj, leRect *res) |
Clips a rectangle to the space of another rectangle. More... | |
void | leRectFromPoints (const lePoint *p1, const lePoint *p2, leRect *res) |
Create rectangle from two points. More... | |
void | leRectToPoints (const leRect *rect, lePoint *p1, lePoint *p2) |
Create rectangle from two points. More... | |
uint32_t | leRectSplit (const leRect *sub, const leRect *obj, leRect res[4]) |
Split rectangles. More... | |
int32_t | leRectCompare (const leRect *l, const leRect *r) |
Determines if two rectangles are similar. More... | |
leBool | leRectsAreSimilar (const leRect *l, const leRect *r) |
Determine if two rectanges are similar. More... | |
Rectangle functions and definitions.
Rectangle management functions.
Clips a rectangle to the space of another rectangle.
Produces a single rectangle after cliping r_rect by l_rect.
l_rect | a rectangle. |
r_rect | a rectangle. |
result | is the new rectangle. |
Clips a rectangle to the space of another rectangle.
Produces a single rectangle after cliping r_rect by l_rect.
l_rect | a rectangle. |
r_rect | a rectangle. |
result | is the adjusted rectangle. |
res | the resultant rectangle |
Combine rectangles.
Returns a single rectangle after combining l_rect and r_rect.
l_rect | a rectangle. |
r_rect | a rectangle. |
res | the resulting rectangle |
Determines if two rectangles are similar.
Determines if l and r</> have the same position and dimensions.
l | a point. |
r | a point. |
Determines if a point is inside a rectangle.
Returns true if point is inside rect.
rect | is the area to search. |
point | is the criteria |
Determines if a rectangle is completely inside another rectangle.
Returns true if l_rect is inside r_rect.
rect | is the area to search. |
point | is the criteria |
Create rectangle from two points.
Creates a rectangle specified by p1 and p2.
p1 | the first point |
p2 | the second point |
res | the resultant rectangle |
Determines if two rectangles are intersecting.
Returns true if l_rect intersects r_rect.
l_rect | a rectangle. |
r_rect | a rectangle. |
Determine if two rectanges are similar.
Determines if l and r are adjancent and vertically or horizontally aligned.
l | a point. |
r | a point. |
Split rectangles.
Splits sub and obj into a maximum of four non-overlapping rectangles res.
sub | the first rectangle. |
obj | the second rectangle. |
res |
Create rectangle from two points.
Returns a rectangle specified by p1 and p2.
rect | the rectangle |
p1 | the point of upper left vertex |
p2 | the point of the lower right vertex |