Home | History | Annotate | Download | only in video

Lines Matching full:intersection

331  * A function to calculate the intersection of two rectangles:
335 SDL_bool SDL_IntersectRect(const SDL_Rect *A, const SDL_Rect *B, SDL_Rect *intersection)
339 /* Horizontal intersection */
346 intersection->x = Amin;
349 intersection->w = Amax - Amin > 0 ? Amax - Amin : 0;
351 /* Vertical intersection */
358 intersection->y = Amin;
361 intersection->h = Amax - Amin > 0 ? Amax - Amin : 0;
363 return (intersection->w && intersection->h);