Get Indices From Rampattribute

Hello

I've a basic question, but unfortunately I can't find any help in the docs or in the web, probably I use the wrong key words. I've a rampAttribute, which has 5 indices (0,1,2,3,4). Then I delete manualy the indices (0,2,3), so that only the indices 1 and 4 left.

Now, I'm looking for a mel command, which returns theses indices (1 and 4). In the APi this would be getExistingArrayAttributeIndices but of course I prefere a Mel solution.

Thanks in advance

flaiver

Hey,

Here you go:

string $tj_rampNode = "myRampName";
int $entries = getAttr -size ($tj\_rampNode+".colorEntryList");

By the way, there are a few tutorials I've posted regarding using ramps for various things. Hope they help.

oops, missed the line you actually wanted!

listAttr -m ($tj_rampNode+".colorEntryList");

That will return a list back with the information you need. The $entries (below) will tell you how many you have.

QUOTE(tjgalda @ 01/04/08, 04:44 PM) [snapback]279206[/snapback]
Hey,

Here you go:

string $tj_rampNode = "myRampName";
int $entries = getAttr -size ($tj\_rampNode+".colorEntryList");
By the way, there are a few tutorials I've posted regarding using ramps for various things. Hope they help.