Restructuring surface tessellation with irregular boundary conditions