Skip to content

Commit

Permalink
comment isWithin usage ref #14256
Browse files Browse the repository at this point in the history
Signed-off-by: m-kro <m.barthauer@t-online.de>
  • Loading branch information
m-kro committed Jan 24, 2024
1 parent ad624c0 commit f23d336
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions tools/sumolib/geomhelper.py
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,7 @@ def minAngleDegreeDiff(d1, d2):


def isWithin(pos, shape):
"""Returns whether the given pos coordinate is inside the polygon shape defined in anticlockwise order."""
angle = 0.
for i in range(0, len(shape) - 1):
p1 = ((shape[i][0] - pos[0]), (shape[i][1] - pos[1]))
Expand Down

0 comments on commit f23d336

Please sign in to comment.