Integrating 3D models with photography
Interested in integrating your 3D work with the real world? This might help
# 1 13-04-2011 , 07:58 AM
Registered User
Join Date: Apr 2011
Posts: 3

How to override an transp' animation in a Layer?

Hello,

I have few objects.
Each object have a material of its own.

all materials have the same Transparency animation.

I want, that in a another layer, I can turn off one of the objects Transparency. (completely, to all frames).

So I have a spacial layer when all other objects have Transparency animation, but that object don't get any Transparency at all.

please help,
thanks for your time . : )

# 2 13-04-2011 , 12:17 PM
Gen's Avatar
Super Moderator
Join Date: Dec 2006
Location: South FL
Posts: 3,522
You will have to assign a separate shader to the object because shaders act the same on all objects to which they're assigned.


- Genny
__________________
::|| My CG Blog ||::
::|| My Maya FAQ ||::
# 3 14-04-2011 , 04:49 PM
Registered User
Join Date: Apr 2011
Posts: 3

thanks

but are you sure that there is no way to have it so the Layer will decide If the object Will get the transp' or not ?

I can do this in XSI with pass partitions (with override on the partition), I believe there is a similar solution in the maya layering system...

# 4 14-04-2011 , 05:14 PM
honestdom's Avatar
The Nurb Herd
Join Date: Oct 2007
Location: London
Posts: 2,381
right click on the transparency in the shader there is a render layer override there.

# 5 14-04-2011 , 06:29 PM
Registered User
Join Date: Apr 2011
Posts: 3

thanks

sorry for asking,

but can you please write me step by step how to do this right ?

thanks.

# 6 15-04-2011 , 02:35 PM
LauriePriest's Avatar
Moderator
Join Date: May 2003
Location: London
Posts: 1,001
Bit of math will do this just fine, my feeling is your animation is coming from seperate animation curves which is standard.

This setup will let you have the flexibility to alter the peaks of the animation per object and to set it to fully transparent or opaque.

You will need to know how to:
make custom attributes, use and create nodes in the hypershade, use the connection editor.

Make two attributes on the transform for each object, one called transMax
and the other called transMin.
In the hypershade graph your shaders, the transforms of your objects (which hold the custom attributes), and then create a set range node, one for each shader.

On each set range node set the old min to zero and old max to 1, then plug your transMin and transMax attributes from your objects translate to the min and max values of the set range node ( do this once for each object).

Plug the output of your animation, (should appear when you graphed your shaders) you might find you have three animCurves for each shader (representing the r, g, b components of the transparency), feel free to delete all but one since your animation is the same. Plug the output of your anim curve into the value x of the set range and then the outValueX of the set range into the transparency R, G and B component of your shader.

This should do what you want... basicaly, by setting the transMin to 1 and 1 will set your shader to be fully transparent per object and setting it to 0 and 0 will set it to fully opaque, you can do any thing inbetween too.

This probably wont update the transparency in your viewport due to the that are being used. Though you can probably do somethign similar to try and get feedback int he viewport, e.g. plug the set range into the colors of a ramp with one color in it (the inputs for this can be found in the connection editor under colorEntryList>colorEntry List[0].color R G B, this will do the same thing but it might display into the viewport since the output isnt coming directly from a math node.

Hope this helps

... This is better than animation layers by the way, alot cleaner and more control .


FX supervisor - double negative
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

Similar Threads