Intersection of lines with 3d objects

I’m building a simulation, in which particles will be coming from a point source, and I want to find their intersection with geometric objects in 3d.

For instance, I will have a pipe structure, made of cylinders, circles etc., and I will have a initial and final point for the particle trajectory(thus, a line). I just want to find out where each line intersect with my geometrical objects.

Are there defined functions for this purpose in ROOT libraries?

You bet there are: