mirror of
https://github.com/zebrajr/opencv.git
synced 2025-12-06 12:19:50 +01:00
Merge pull request #22526 from paroj:pyrect
This commit is contained in:
commit
2763f988da
|
|
@ -2017,6 +2017,15 @@ double jaccardDistance(const Rect_<_Tp>& a, const Rect_<_Tp>& b) {
|
||||||
return 1.0 - Aab / (Aa + Ab - Aab);
|
return 1.0 - Aab / (Aa + Ab - Aab);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** @brief Finds out if there is any intersection between two rectangles
|
||||||
|
*
|
||||||
|
* mainly useful for language bindings
|
||||||
|
* @param rect1 First rectangle
|
||||||
|
* @param rect2 Second rectangle
|
||||||
|
* @return the area of the intersection
|
||||||
|
*/
|
||||||
|
CV_EXPORTS_W inline double rectangleIntersectionArea(const Rect2d& a, const Rect2d& b) { return (a & b).area(); }
|
||||||
|
|
||||||
////////////////////////////// RotatedRect //////////////////////////////
|
////////////////////////////// RotatedRect //////////////////////////////
|
||||||
|
|
||||||
inline
|
inline
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user