Wiki Page Content

Differences between revisions 8 and 9
Revision 8 as of 2010-10-10 18:10:51
Size: 1191
Editor: SheenaSmith
Comment: update content - pointers, structs
Revision 9 as of 2010-10-16 05:58:42
Size: 1223
Editor: SheenaSmith
Comment: update content - pointers, structs
Deletions are marked like this. Additions are marked like this.
Line 20: Line 20:
||'''clip'''||an [[SDL_Rect]] used for clipping or NULL to enclose all points; see [[#Remarks|Remarks]] for details||
||'''result'''||--(a pointer to)-- an [[SDL_Rect]] to be filled in||
||'''clip'''||an [[SDL_Rect]] structure used for clipping or NULL to enclose all points; see [[#Remarks|Remarks]] for details||
||'''result'''||an [[SDL_Rect]] structure filled in with the minimal enclosing rectangle||

SDL_EnclosePoints

Use this function to calculate a minimal rectangle enclosing a set of points.

Syntax

SDL_bool SDL_EnclosePoints(const SDL_Point* points,
                           int              count,
                           const SDL_Rect*  clip,
                           SDL_Rect*        result)

Function Parameters

points

an array of SDL_Point structures representing points to be enclosed

count

the number of structures in the points array

clip

an SDL_Rect structure used for clipping or NULL to enclose all points; see Remarks for details

result

an SDL_Rect structure filled in with the minimal enclosing rectangle

Return Value

Returns SDL_TRUE if any points were enclosed or SDL_FALSE if all the points were outside of the clipping rectangle.

Code Examples

You can add your code example here

Remarks

If clip is not NULL then only points inside of the clipping rectangle are considered.


CategoryAPI, CategoryRect

None: SDL_EnclosePoints (last edited 2010-10-16 05:58:42 by SheenaSmith)

Feedback
Please include your contact information if you'd like to receive a reply.
Submit