PDA

View Full Version : Help with controlling nConstraint strength with texture


eaclou
09-15-2010, 04:13 PM
I'm trying to create a set-up where a layered texture or nested ramps (not files) control the strength of an nConstraint through its texture properties, but can't get it to work.

I started by creating a ramp (started simply with a white to black plain ramp), then I painted the nConstraint Strength and saved a file to see how it made its connection, and replaced the file with the ramp texture.

I couldn't achieve a situation where the constraint's strength varied like it should being driven by a ramp. It just took the 0position value and applied it to the whole mesh. I was able to achieve varied behavior from directly painting the texture onto the mesh, but that won't allow me to dynamically alter the ramps throughout the animation.

What are the connections that need to be in place? The default that Maya used was the .outAlpha channel from a file. But once i initially broke that connection and later re-created it (.outAlpha to strength) it doesn't work now.

HowardM
09-15-2010, 04:39 PM
unfortunately Layered Texture doesnt work :(

http://forums.cgsociety.org/showthread.php?f=86&t=855775

but you can layer ramps within ramps.....

eaclou
09-15-2010, 05:18 PM
I'm not able to get it working with just a simple ramp though, also. The only way i've gotten it to sort of work is by just using the paint values by texture tool and saving as a file. However when i severed that connection and manually re-did it, it no longer worked - is there a hidden connection somewhere?

I started from scratch to make sure everything was clean.

UV'ed original mesh, delete history, duplicate, create nCloth, then made nConstraint "attract to matching mesh"
-went to the strength attribute of the nConstraint, right-click --> create new texture --> ramp white to black.

But all it does is apply the value at 0 to ALL of the components. Is there something special I have to do in the graph editor to get this to work? Thanks.

HowardM
09-15-2010, 05:23 PM
try this out -
http://forums.cgsociety.org/showthread.php?f=86&t=866651

in Hypergraph/Shade make sure youve got Texture selected in the component node...

eaclou
09-15-2010, 05:32 PM
Thanks Howard, I think I figured it out just now though, and feel stupid.

I'm pretty new to getting really down & dirty with the hypergraph connections, and was connecting .alphaOut to .strength rather than .strengthMap

So far it seems to be working. I'm not sure why it uses .alphaOut though instead of outColor.

Now to start on nesting those ramps and encountering new and annoying errors :)

HowardM
09-15-2010, 05:47 PM
No worries!

Ya, lil things like that you learn by trial and error ;)

CGTalk Moderation
09-15-2010, 05:47 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.