Stick an object to a point

Become a member of the CGSociety

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

THREAD CLOSED
 
Thread Tools Search this Thread Display Modes
Old 02 February 2013   #1
Stick an object to a point

I think I saw a tut showing a way to stick an object to a point. I have so many tuts and I can't remember where it is. I think it was a demo showing a button object sticking to a vertex point on a shirt/jacket object. How can I do this? What I really want to do though is have a null object stick to a point on a character face mesh. The null controls a cluster for deforming areas on the face. Like brows, lips, etc. When I rotate the head, the nulls get left behind.
 
Old 02 February 2013   #2
Funny--this seems to be the theme of the day.

You can do so with the point node via expresso. (there are other ways too)

http://forums.cgsociety.org/showthr...?f=47&t=1094415

Add an expresso tag to the object you want to stick.

Double click to open the xpresso manager.

Drag the object and the target object into the window.

Right click anywhere on the xpresso manager window. You will get a contextual menu. Go to New node> expresso > general > point

Put your target object on the left, your "sticky" object on the right and the point node in between:




On the target object on the left, click the right side corner to get a dropdown of available output ports. Choose "object"

Feed the object into the object port on the left side of the point node.

Output the point position to the sticky object. Add it to the position port.

Now click on the object in the editor window and select a point you wish to stick to.

In your structure manager you can find the point number of the selected point.

Now click on your point node, type in that number in the attributes manager under Point index. Click Use deformed points if the target object will be moving.

That should do it.

Last edited by JoelDubin : 02 February 2013 at 06:58 PM.
 
Old 02 February 2013   #3
use the point node in xpresso or clamp constraint (i prefer the node)
__________________
www.x-particle.com
 
Old 02 February 2013   #4
I haven't had much luck with the clamp constraint. It always messes up the head mesh when I rotate the head. I will try the expresso route like Joel mentioned above.
 
Old 02 February 2013   #5
The Clamp constraint should work fine. Why is it messing up the head mesh? Did you attach a deformer as a child of the constrained Null? You might be running into conflicting expressions, if that's the case (Clamped Null trying to follow deformations>Deformations trying to follow Clamped Null kind of loop).
__________________
One on one Online Instructor for Cinema4D | Visit www.Fluffy4D.com for more info.
 
Old 02 February 2013   #6
Joel, it whacks out on me using the xpresso. I attached the scene file. Anyone know what is wrong?
Attached Files
File Type: zip Cartoon head 3.zip (164.8 KB, 12 views)
 
Old 02 February 2013   #7
Originally Posted by fluffouille: The Clamp constraint should work fine. Why is it messing up the head mesh? Did you attach a deformer as a child of the constrained Null? You might be running into conflicting expressions, if that's the case (Clamped Null trying to follow deformations>Deformations trying to follow Clamped Null kind of loop).
I am not usre. can you check my scene file I just posted here. I have clusters added to the head mesh to deform the mouth/lips. The clusters add nulls that I have in a group null. When I rotate the head using the head joint, the head mesh gets all crazy using the clamp and now the xpresso. It works without those, but the nulls for the clusters get left behind when I rotate the head. I want to have the cluster nulls follow the head motion for animation.

I have tried many ways to rig the head. Clusters, bones, spline deformers. I always have problems when moving the head. I think the bones worked the best and followed head motion. The spline deformer would be good for me, but it takes me a long time to get it to work. It always has interaction. Such as the lower lip mid point also moves the upper lip. I have tried many ways. Is there some way to mask off areas in the spline deforming. so the upper lip doesn't move when i pose the lower lip. I think I saw that in some other tuts for another app, like maya.
 
Old 02 February 2013   #8
Yeah, your problem is conflicting expression.
Basically, you are trying to have the Nulls follow a specific point, then drive the position of the cluster as well. Problem is, your cluster is already driving that point position, so your expression and cluster keep adding up their own point position correction, and get your mesh all out of whack.

Why don't you use morphs for this? You can link your morph shapes to Null position if you want.

Otherwise you'd have to use a different setup for what you are trying to do, which is a lot more complicated without running into this loop issue. There are ways to do it, though (I'd have to spend some time on it to give you the correct workflow).
__________________
One on one Online Instructor for Cinema4D | Visit www.Fluffy4D.com for more info.
 
Old 02 February 2013   #9
Or you could simply constraint the group with all your Null controllers to the Head joint object.
Not a true point constraint, but should do the job for what you are trying to do.

Constraining the controller to a specific point has advantages only if you have several deformations going on over the same point (say, a FFD in addition to your clusters), that way the controller always follows the shape of the object. But here, there's no point (unless you have more deformers not included in this file).
__________________
One on one Online Instructor for Cinema4D | Visit www.Fluffy4D.com for more info.
 
Old 02 February 2013   #10
I had the same feeling that morphs would be the easiest/best way. I see some rigs online where they have all these face controls to go beyond the morph and I haven't figured out how in c4d. thanks for help

Originally Posted by fluffouille: Yeah, your problem is conflicting expression.
Basically, you are trying to have the Nulls follow a specific point, then drive the position of the cluster as well. Problem is, your cluster is already driving that point position, so your expression and cluster keep adding up their own point position correction, and get your mesh all out of whack.

Why don't you use morphs for this? You can link your morph shapes to Null position if you want.

Otherwise you'd have to use a different setup for what you are trying to do, which is a lot more complicated without running into this loop issue. There are ways to do it, though (I'd have to spend some time on it to give you the correct workflow).
 
Old 02 February 2013   #11
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
CGSociety
Society of Digital Artists
www.cgsociety.org

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

All times are GMT. The time now is 12:55 PM.


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