raycast and linecast

Unity3D has a way of finding out if there are any objects occluding the view between two points (linecast) and also what it visible from a point (raycast) and will return a hit list. I have not yet found that in Panda3D.

Where do I look?

This is possible by creating a CollisionTraverser and a CollisionRay or CollisionLine or CollisionSegment, and using a CollisionHandlerQueue to store the resulting points generated by the collision when you call traverse(). This is demonstrated in the Chessboard sample program, among other places.

You can also use Panda’s Bullet integration to similar effect, but this is overkill for simple raycasts.