mirror of
https://github.com/apache/nuttx.git
synced 2026-09-15 09:03:01 +08:00
Add vectsubtract() and rectinside()
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@1371 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
@@ -351,6 +351,18 @@ EXTERN void nxgl_vectoradd(FAR struct nxgl_point_s *dest,
|
||||
FAR const struct nxgl_point_s *v1,
|
||||
FAR const struct nxgl_point_s *v2);
|
||||
|
||||
/****************************************************************************
|
||||
* Name: nxgl_vectorsubtract
|
||||
*
|
||||
* Description:
|
||||
* Add subtract vector v2 from vector v1 and return the result in vector dest
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
EXTERN void nxgl_vectorsubtract(FAR struct nxgl_point_s *dest,
|
||||
FAR const struct nxgl_point_s *v1,
|
||||
FAR const struct nxgl_point_s *v2);
|
||||
|
||||
/****************************************************************************
|
||||
* Name: nxgl_rectintersect
|
||||
*
|
||||
@@ -401,6 +413,17 @@ EXTERN void nxgl_nonintersecting(FAR struct nxgl_rect_s result[4],
|
||||
EXTERN boolean nxgl_rectoverlap(FAR struct nxgl_rect_s *rect1,
|
||||
FAR struct nxgl_rect_s *rect2);
|
||||
|
||||
/****************************************************************************
|
||||
* Name: nxgl_rectinside
|
||||
*
|
||||
* Description:
|
||||
* Return TRUE if the point pt lies within rect.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
EXTERN boolean nxgl_rectinside(FAR const struct nxgl_rect_s *rect,
|
||||
FAR const struct nxgl_point_s *pt);
|
||||
|
||||
/****************************************************************************
|
||||
* Name: nxgl_nullrect
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user