Extension written in C++ with basic geometric functions.
This function counts how many convex r-holes are in points (the point set may be colored). It is an implementation of the algorithm presented in “Searching for Empty Convex Polygons” [1]_
Parameters: | p : list
q : Analogous to p
|
---|---|
Returns: | t : int
|
Notes
The coordinates of the points should be less than or equal to \(2^{30}\) to prevent overflow on the C++ side.
Examples
>>> import geometricbasicsCpp as gb
>>> p=[0,0]
>>> q=[1,0]
>>> p=[1,1]
>>> gb.turn(p, q, r)
-1