Light ray angle of incidence

Is there a way using nodes to get the light ray angle of incidence? That is, the angle at which a light ray hits an object?

Kind of like fresnel, but not from the camera’s perapective.

Probably not in the form you want. You can do manual/fake calculation of an emission shader based on a point (such as diffuse and phong), but not truly react to “lights”. In Cycles, this information is only available to shaders. In Eevee, you can plug shader outputs into the shader2rgb node. You can render out and use the result as a screen space texture in Cycles.

It’s simply impossible in cycles, as it works the other way round for performance reasons (importance sampling). First you calculate the material shader, then the system determines the best direction to shoot a ray towards.