I\'ve got the following information:
There exists a sphere with origin (0,0,0) and radius R. After doing a ray-sphere intersection I know a point (XYZ) in 3D space t
I guess it should not be difficult to find the spherical polar coordinates from x,y,z (3d-coordinate system).
r is always constant if it's on surface.

(90 - θ) your latitude (negative means it's on the bottom) as it's measured from top.

φ is your longitude. (but not quite sure about longitude system)

Also check this diagram from wikipedia.
