(file_in='', file_out='ctrlpts_flip.txt')
Flips u and v directions of a 2D control points file and saves flipped coordinates to a file.

    :param file_in: name of the input file (to be read)
    :type file_in: str
    :param file_out: name of the output file (to be saved)
    :type file_out: str
    :raises IOError: an error occurred reading or writing the file
Flips u and v directions of a 2D control points file and saves flipped coordinates to a file.
Flips u and v directions of a 2D control points file and saves flipped coordinates to a file .
def flip_ctrlpts2d_file(file_in='', file_out='ctrlpts_flip.txt'):
    """ Flips u and v directions of a 2D control points file and saves flipped coordinates to a file.

    :param file_in: name of the input file (to be read)
    :type file_in: str
    :param file_out: name of the output file (to be saved)
    :type file_out: str
    :raises IOError: an error occurred reading or writing the file
    """
    # Read control points
    ctrlpts2d, size_u, size_v = _read_ctrltps2d_file(file_in)

    # Flip control points array
    new_ctrlpts2d = flip_ctrlpts2d(ctrlpts2d, size_u, size_v)

    # Save new control points
    _save_ctrlpts2d_file(new_ctrlpts2d, size_u, size_v, file_out)
def flip_ctrlpts2d_file ( file_in = '' , file_out = 'ctrlpts_flip.txt' ) : # Read control points ctrlpts2d , size_u , size_v = _read_ctrltps2d_file ( file_in ) # Flip control points array new_ctrlpts2d = flip_ctrlpts2d ( ctrlpts2d , size_u , size_v ) # Save new control points _save_ctrlpts2d_file ( new_ctrlpts2d , size_u , size_v , file_out )