Sampling against geometry normals I am writing a basic raytracer and have implemented normal maps. However, when using normal maps, sometimes the rays generated are opposite to the surface's geometry normal, so that the rays are reaching light sources behind the object. If I kill the ray, the shading results looked faceted and the surface normals are apparent. If I don't kill the ray, the ray reaches light sources on the opposite side of the geometry.

How is this handled normally?
That is, to my knowledge, a problem without a proper solution. You're seeing the discrepancy between shading normal and geometry normal and it becomes obvious, that the shading normal is just a trick. PBRT has a paragraph on this, their solution is to look at the geometric normal to determine whether to call the BRDF (reflection) or the BTDF (transmission), then to pass the shading normal to the BxDF. Still, this doesn't work robustly in all situations.

This problem is also known and described for production proven render engines:
http://blog.irayrender.com/post/29042276644/shadow-acne-and-the-shadow-terminator
The solution suggested for iRay is to use displacement mapping instead of normal maps. This way, shading and geometry normal are in agreement again.