SDL_GetRectEnclosingPoints

Calculate a minimal rectangle enclosing a set of points.

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

extern (C) nothrow @nogc extern
bool
SDL_GetRectEnclosingPoints

Parameters

points const(SDL_Point)*

an array of SDL_Point structures representing points to be enclosed.

count int

the number of structures in the points array.

clip const(SDL_Rect)*

an SDL_Rect used for clipping or NULL to enclose all points.

result SDL_Rect*

an SDL_Rect structure filled in with the minimal enclosing rectangle.

Return Value

Type: bool

true if any points were enclosed or false if all the points were outside of the clipping rectangle.

Meta