Press "Enter" to skip to content

aoSmoothing

[code lang="c"]
// 
// 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[$i]); $i++) 
	{
		select $selection[$i];
		polySmooth -c 0.8 -dv 1;
	}
}

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