Computes intersection (common area) of two give rectangles.
Class method
Syntax
var common = Rect.intersection( first_rectangle, second_rectangle );
Parameters
Parameter | Description |
---|---|
first_rectangle | First rectangle |
second_rectangle | Second rectangle |
Returns
Rectangle representing intersection or null if rectangles do not intersect.