attribute existence

Become a member of the CGSociety

Connect, Share, and Learn with our Large Growing CG Art Community. It's Free!

Thread Tools Display Modes
  09 September 2005
attribute existence

hi all,
I am trying to use attributeExists to find out if the attribute is there in the scene. Such as:

attributeExists "noise" "ramp1";

it returns 1, that works fine, however if i do this:

attributeExists "colorEntryList[1].position" "ramp1";

it returns 0 even if it exists under the ramp node.

I guess its because of the position attribute is hidden deeper than other attribute, which cannot be seen by the script. I have found out the way to display the number of entries in colorEntryList. However, it does not mean that all entry index starts with 0. Thus, I just need to find out a way to check if the colorEntryList[0] exist under the ramp node.

Thanks in advance.....

  09 September 2005
Thumbs up

int $pExists = `attributeExists "colorEntryList.position" "ramp1.colorEntryList"` ;
int $cExists = `attributeExists "colorEntryList.color" "ramp1.colorEntryList"` ;

  09 September 2005
Thread automatically closed

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.
CGTalk Policy/Legalities
Note that as CGTalk Members, you agree to the terms and conditions of using this website.
Thread Closed share thread

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Society of Digital Artists

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump

All times are GMT. The time now is 09:25 PM.

Powered by vBulletin
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.