aoSmoothing

// 
// aoKit
// Andrew Odendaal's Maya Script Kit
// Software developed by Andrew Odendaal
// Code compatible with versions 7 - 8.5
//
// Author : Andrew Odendaal
// E-mail : [email protected]
// Website: http://www.andrewodendaal.com
// 

// turn on smooth
global proc aoKitSmoothOn()
{
	string $selection[] = `ls -sl`;
	for ($i = 0; $i < size($selection&#91;$i&#93;); $i++) 
	{
		select $selection&#91;$i&#93;;
		polySmooth -c 0.8 -dv 1;
	}
}

// turn off smooth
global proc aoKitSmoothOff()
{
	string $selection&#91;&#93; = `ls -sl`;
	for ($i = 0; $i < size($selection&#91;$i&#93;); $i++) 
	{
		select $selection&#91;$i&#93;;
		
		string $del&#91;&#93; = `ls -type "polySmoothFace"`;print $del;
		if (`size ($del)` > 0)
			delete $del[0];   
	}
}

Leave a Reply

Your email address will not be published.