date:22 sep 2008
language:mel script
maya:version 2009+
This script rotates each uv shell in your selection so that its bounding box is as small as possible. With most shells this results in a straight orientation.

Note: This is script is now also included in the xformUV editor.

You can download this script here (4.8 kb zip):

Windows | Maya 2013
1) Open the zip file and copy the scripts (.mel) to this directory:

2) Copy the icons (.bmp) to this directory:

3) Restart Maya or enter rehash in the script editor.

Select uvs and enter this command in the script editor:

TIP: The shell definition pass works faster if you select less uvs per shell. This is mainly an issue with very high uv counts (10k+). Ideally you only need to select one uv per shell.

Version History
v1.1.0 – 29 Sep 2008 – Rewrote the orient function.
v1.0.0 – 22 Jun 2008 – Created