I think this generalizes to 3D now.