Cleanups to calc_light/calc_sphere (might want to move back to 3dmath
for consistency with upstream)