Introduction to Maya - Modeling Fundamentals Vol 1
This course will look at the fundamentals of modeling in Maya with an emphasis on creating good topology. We'll look at what makes a good model in Maya and why objects are modeled in the way they are.
# 1 08-01-2009 , 01:38 AM
Dann's Avatar
Registered User
Join Date: Feb 2003
Location: Los Angeles
Posts: 695

namespaceInfo

Hey all,

I'm trying to figure out a way to query what objects are in each namespace in my file. Let's assume that I've imported and/or referenced a dozen objects with use namespace turned on so that they all reside in a unique namespace.

I can use 'namespaceInfo -lon' to get an array of my namespaces.
I can use 'namespaceInfo -ls ' to get an array of the objects in the current namespace.
However, I can find no way to get an array of a specified namespace.

I was hoping I could do something like:
string $nameSpaces[];
string $objects[];
$nameSpaces = `namespaceInfo -lon`;
$objects = `namespaceInfo -ls $nameSpaces[0] `;

That doesn't work though. I tried setting the namespace first:
namespace -set $nameSpaces[0];
but that seems to put me into a state where Maya can no longer find any of the other namespaces.

Thanks.
-dann

# 2 10-01-2009 , 09:38 PM
Dann's Avatar
Registered User
Join Date: Feb 2003
Location: Los Angeles
Posts: 695
ooooooo....

Did I stump the forum?

I love it when I do that.

Makes me proud.

user added image

# 3 10-01-2009 , 10:34 PM
honestdom's Avatar
The Nurb Herd
Join Date: Oct 2007
Location: London
Posts: 2,381
you lost me at namespace! i know very little mel, but good luck user added image

Posting Rules Forum Rules
You may not post new threads | You may not post replies | You may not post attachments | You may not edit your posts | BB code is On | Smilies are On | [IMG] code is On | HTML code is Off