area_intersection_rectangle2area_intersection_rectangle2AreaIntersectionRectangle2AreaIntersectionRectangle2area_intersection_rectangle2面积交集矩形2(算子)
名称
area_intersection_rectangle2area_intersection_rectangle2AreaIntersectionRectangle2AreaIntersectionRectangle2area_intersection_rectangle2 — 计算定向矩形的交集面积。
签名
Herror area_intersection_rectangle2(double Rect1Row, double Rect1Column, double Rect1Phi, double Rect1Length1, double Rect1Length2, double Rect2Row, double Rect2Column, double Rect2Phi, double Rect2Length1, double Rect2Length2, double* AreaIntersection)
Herror T_area_intersection_rectangle2(const Htuple Rect1Row, const Htuple Rect1Column, const Htuple Rect1Phi, const Htuple Rect1Length1, const Htuple Rect1Length2, const Htuple Rect2Row, const Htuple Rect2Column, const Htuple Rect2Phi, const Htuple Rect2Length1, const Htuple Rect2Length2, Htuple* AreaIntersection)
void AreaIntersectionRectangle2(const HTuple& Rect1Row, const HTuple& Rect1Column, const HTuple& Rect1Phi, const HTuple& Rect1Length1, const HTuple& Rect1Length2, const HTuple& Rect2Row, const HTuple& Rect2Column, const HTuple& Rect2Phi, const HTuple& Rect2Length1, const HTuple& Rect2Length2, HTuple* AreaIntersection)
static void HOperatorSet.AreaIntersectionRectangle2(HTuple rect1Row, HTuple rect1Column, HTuple rect1Phi, HTuple rect1Length1, HTuple rect1Length2, HTuple rect2Row, HTuple rect2Column, HTuple rect2Phi, HTuple rect2Length1, HTuple rect2Length2, out HTuple areaIntersection)
def area_intersection_rectangle2(rect_1row: Union[float, int], rect_1column: Union[float, int], rect_1phi: Union[float, int], rect_1length_1: Union[float, int], rect_1length_2: Union[float, int], rect_2row: MaybeSequence[Union[float, int]], rect_2column: MaybeSequence[Union[float, int]], rect_2phi: MaybeSequence[Union[float, int]], rect_2length_1: MaybeSequence[Union[float, int]], rect_2length_2: MaybeSequence[Union[float, int]]) -> Sequence[float]
def area_intersection_rectangle2_s(rect_1row: Union[float, int], rect_1column: Union[float, int], rect_1phi: Union[float, int], rect_1length_1: Union[float, int], rect_1length_2: Union[float, int], rect_2row: MaybeSequence[Union[float, int]], rect_2column: MaybeSequence[Union[float, int]], rect_2phi: MaybeSequence[Union[float, int]], rect_2length_1: MaybeSequence[Union[float, int]], rect_2length_2: MaybeSequence[Union[float, int]]) -> float
描述
area_intersection_rectangle2area_intersection_rectangle2AreaIntersectionRectangle2AreaIntersectionRectangle2AreaIntersectionRectangle2area_intersection_rectangle2 计算两个定向矩形(即 rectangle2 类型)的交集面积,它们分别由参数(中心点 (Rect1RowRect1RowRect1RowRect1Rowrect1Rowrect_1row, Rect1ColumnRect1ColumnRect1ColumnRect1Columnrect1Columnrect_1column)、方向 Rect1PhiRect1PhiRect1PhiRect1Phirect1Phirect_1phi 以及半边长 Rect1Length1Rect1Length1Rect1Length1Rect1Length1rect1Length1rect_1length_1 与 Rect1Length2Rect1Length2Rect1Length2Rect1Length2rect1Length2rect_1length_2)和(中心点 (Rect2RowRect2RowRect2RowRect2Rowrect2Rowrect_2row, Rect2ColumnRect2ColumnRect2ColumnRect2Columnrect2Columnrect_2column)、方向 Rect2PhiRect2PhiRect2PhiRect2Phirect2Phirect_2phi 以及半边长 Rect2Length1Rect2Length1Rect2Length1Rect2Length1rect2Length1rect_2length_1 与 Rect2Length2Rect2Length2Rect2Length2Rect2Length2rect2Length2rect_2length_2) 定义。交集区域返回到 AreaIntersectionAreaIntersectionAreaIntersectionAreaIntersectionareaIntersectionarea_intersection 中。如果为第二个矩形提供了多个参数值,则输出为元组,包含第一个矩形与每个第二个矩形的交集面积。若未为第二个矩形提供参数,则 AreaIntersectionAreaIntersectionAreaIntersectionAreaIntersectionareaIntersectionarea_intersection 返回空元组。
执行信息
- 多线程类型:可重入(与非独占算子并行运行)。
- 多线程作用域:全局(可从任何线程调用)。
- 未采用并行化处理。
参数
Rect1RowRect1RowRect1RowRect1Rowrect1Rowrect_1row (输入控制) rectangle2.center.y → HTupleUnion[float, int]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)
第一个矩形的中心行坐标。
Rect1ColumnRect1ColumnRect1ColumnRect1Columnrect1Columnrect_1column (输入控制) rectangle2.center.x → HTupleUnion[float, int]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)
第一个矩形的中心列坐标。
Rect1PhiRect1PhiRect1PhiRect1Phirect1Phirect_1phi (输入控制) rectangle2.angle.rad → HTupleUnion[float, int]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)
正水平轴与第一个矩形第一条边之间的夹角(单位:弧度)。
Rect1Length1Rect1Length1Rect1Length1Rect1Length1rect1Length1rect_1length_1 (输入控制) rectangle2.hwidth → HTupleUnion[float, int]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)
第一个矩形第一个边的一半长度。
Rect1Length2Rect1Length2Rect1Length2Rect1Length2rect1Length2rect_1length_2 (输入控制) rectangle2.hheight → HTupleUnion[float, int]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)
第一个矩形第二个边的一半长度。
Rect2RowRect2RowRect2RowRect2Rowrect2Rowrect_2row (输入控制) rectangle2.center.y(-array) → HTupleMaybeSequence[Union[float, int]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)
第二个矩形的中心行坐标。
Rect2ColumnRect2ColumnRect2ColumnRect2Columnrect2Columnrect_2column (输入控制) rectangle2.center.x(-array) → HTupleMaybeSequence[Union[float, int]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)
第二个矩形的中心列坐标。
Rect2PhiRect2PhiRect2PhiRect2Phirect2Phirect_2phi (输入控制) rectangle2.angle.rad(-array) → HTupleMaybeSequence[Union[float, int]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)
正水平轴与第二个矩形第一条边之间的夹角(单位:弧度)。
Rect2Length1Rect2Length1Rect2Length1Rect2Length1rect2Length1rect_2length_1 (输入控制) rectangle2.hwidth(-array) → HTupleMaybeSequence[Union[float, int]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)
第二个矩形第一个边的一半长度。
Rect2Length2Rect2Length2Rect2Length2Rect2Length2rect2Length2rect_2length_2 (输入控制) rectangle2.hheight(-array) → HTupleMaybeSequence[Union[float, int]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)
第二个矩形第二个边的一半长度。
AreaIntersectionAreaIntersectionAreaIntersectionAreaIntersectionareaIntersectionarea_intersection (输出控制) real(-array) → HTupleSequence[float]HTupleHtuple (real) (double) (double) (double)
第一个矩形与第二个矩形的交集面积。
结果
如果参数有效,算子
area_intersection_rectangle2area_intersection_rectangle2AreaIntersectionRectangle2AreaIntersectionRectangle2AreaIntersectionRectangle2area_intersection_rectangle2 返回值 2 ( H_MSG_TRUE )。
另见
gen_rectangle2gen_rectangle2GenRectangle2GenRectangle2GenRectangle2gen_rectangle2,
intersection_segmentsintersection_segmentsIntersectionSegmentsIntersectionSegmentsIntersectionSegmentsintersection_segments,
intersection_segment_lineintersection_segment_lineIntersectionSegmentLineIntersectionSegmentLineIntersectionSegmentLineintersection_segment_line,
intersection_segment_contour_xldintersection_segment_contour_xldIntersectionSegmentContourXldIntersectionSegmentContourXldIntersectionSegmentContourXldintersection_segment_contour_xld,
intersection_line_contour_xldintersection_line_contour_xldIntersectionLineContourXldIntersectionLineContourXldIntersectionLineContourXldintersection_line_contour_xld,
intersection_contours_xldintersection_contours_xldIntersectionContoursXldIntersectionContoursXldIntersectionContoursXldintersection_contours_xld
模块
基础