PDA

View Full Version : Loop Statements


Gabester
08-24-2005, 01:21 AM
Hi All,

I'd like to create a loop statement that will take into account all the texture files that are in my hypershade editor, then reload the textures 1 by 1. Or by that I mean reload all textures automatically.

My only problem is that I don't understand loop statements. Could anyone give me a heads up?

Thanks,

Gabe

swardson
08-24-2005, 03:35 AM
what you are going to want to do is this.

this isnt the exact syntax because I dont have maya open but basicly like this.

string $textures[] = `ls -exactType "texture"`;

for ($each in $textures){

command to reload texture;

}



Hope this helps,
Brad

harmless
08-27-2005, 08:06 PM
No need to reinvent the wheel ;)

http://www.highend3d.com/maya/downloads/mel_scripts/interface_display/471.html

CGTalk Moderation
08-27-2005, 08:06 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.