PDA

View Full Version : Mesh Switcheroo


paraplex
04-03-2008, 03:33 PM
Hi,

I'm looking to try and set up part of my rig that switches (instantly) from one mesh to another.

For example, I want to switch my regular mouth mesh out and replace it with one of an expandable set of new mouth meshes instantly.

Think about flushed away, where the mouthes switched (rather than blend shaped) to emulate the feel of stop motion animation. Does anyone know how to achieve this?

Short of this, a simple, riggable solution to switch between multiple textures might work for me. (Layered Shader is clunky and doesn't preview well) but the mesh solution is really what i'm looking for...

If anyone has any tips on either of these, I'd really appreciate it :)

Cheers,
Lachlan

_stev_
04-03-2008, 05:18 PM
This is actually pretty easy to do. All you have to do is have all the meshes you'd like to switch skinned to the rig, and you toggle the visibility using a custom attribute. Using a condition node (Found in the Hypershade under "Create > General Utilities") you can toggle which mesh is visible.

Setup a custom attribute called "meshSwitcher" or something. Make it an integer type. Then make a condition node for each mesh and set the condition statement to "Equal" and a different number for each mesh in the "Second Term" attribute. Set the If True value to 1 and if False Value to 0 and connect the output to the visibility of the mesh. Now connect your custome switcher attribute to the "First Term" of each condition. Now when you change your attribute one mesh will be visible on each number.

You could do a similar setup for textures too, maybe using a layered shader or something.

Stev

CGTalk Moderation
04-03-2008, 05:18 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.