Paths are now computed more efficiently

Still quite expensive though! We should look into optimising the mesh
even more.