While messing around with Panda3D to see if I can use it in order to solve some simple geometric problems, I've got this littel test done:
def def_planes_intersect():
"""Intersects the plane defined by the xy and xz axis'."""
xy = Plane()
xz = Plane((LPoint3f(1, 0, 1), LPoint3f(2, 0, 1), LPoint3f(1, 0, 2)))
if xy.intersectsPlane((0, 10, 0), (1, 0, 0), xz) is True:
print("works")
else:
print("doesn't")
It works as intended, but what I don't understand is how I can take the LPoint3f and LVector3f that define the intersection.
In the Panda3D docs it says:
intersectsPlane(from: LPoint3f, delta: LVector3f, other: LPlanef) → bool
Returns true if the two planes intersect, false if they do not. If they do intersect, then from and delta are filled in with the parametric representation of the line of intersection: that is, from is a point on that line, and delta is a vector showing the direction of the line.
What do they mean by from and delta are filled in?