Converting an unstructured quadrilateral/hexahedral mesh to a rational T-spline