Add distance test to shadowCoeff