See my answer in Screen Space Curvature for better surface detail visualization (+implementation details) - #4 by stephomi