Function SDL_GetRectIntersection
pub unsafe extern "C" fn SDL_GetRectIntersection(
A: *const SDL_Rect,
B: *const SDL_Rect,
result: *mut SDL_Rect,
) -> bool
Available on crate feature
dep_sdl3
only.Expand description
Calculate the intersection of two rectangles.
If result
is NULL then this function will return false.
§Parameters
A
: anSDL_Rect
structure representing the first rectangle.B
: anSDL_Rect
structure representing the second rectangle.result
: anSDL_Rect
structure filled in with the intersection of rectanglesA
andB
.
§Return value
Returns true if there is an intersection, false otherwise.
§Availability
This function is available since SDL 3.2.0.