pysal.lib.cg.
get_rectangle_point_intersect
(rect, pt)[源代码]¶返回矩形与点的交集。
获取矩形点相交(矩形,点)->点
参数: |
|
---|
实例
>>> rect = Rectangle(0, 0, 5, 5)
>>> pt = Point((1, 1))
>>> i = get_rectangle_point_intersect(rect, pt)
>>> str(i)
'(1.0, 1.0)'
>>> pt2 = Point((10, 10))
>>> get_rectangle_point_intersect(rect, pt2)