06-02-2023, 02:08 PM
I was encountering some strange behavior of Collision_Line(), so I created a test workstation to troubleshoot.
When testing in the attached workstation, I would expect a collision to occur between the object and the line from [0,0,0] to [0,0,100]. However, running the code below indicates that no collision occurs.
What's going on here?
When testing in the attached workstation, I would expect a collision to occur between the object and the line from [0,0,0] to [0,0,100]. However, running the code below indicates that no collision occurs.
Code:
from robodk import *
RDK = robolink.Robolink()
obj = RDK.Item('my_obj')
RDK.Render(True)
print("Testing Collision_Line().")
print("\tRender: True")
print("\tObject in the way")
[collided, item, pt] = RDK.Collision_Line([0, 0, 0], [0, 0, 100])
print("\tResult: collided=" + str(collided) + "\n")
What's going on here?