Consider a triangle (T) in 3D space of given vertices A, B, and C.
A given ray (R) (assumed to be in the direction of the x-axis) hits the triangle at one of its vertices - say A.
Let $\theta$ be the angle between vectors AB and AC.
Let $\beta$ be the projection of $\theta$ onto the plane perpendicular to the ray and containing vertex A.
How to find $\beta$ ?
Image source: Jing Li, Wencheng Wang,Fast and robust GPU-based point-in-polyhedron determination, Computer-Aided Design, Volume 87, 2017, Pages 20-28, ISSN 0010-4485, https://doi.org/10.1016/j.cad.2017.02.001.