Beer glass scene creation
This course contains a little bit of everything with modeling, UVing, texturing and dynamics in Maya, as well as compositing multilayered EXR's in Photoshop.
# 1 05-11-2008 , 10:32 AM
Registered User
Join Date: Nov 2008
Location: Hampshire, UK
Posts: 2

Rigging - Eye Lookat using Planar Proj

Hi Guys,

My first post - I hope you can help!

Overview : I have a character with non-spherical eyes so a simple aim constraint will not suffice as the mesh will poke through as it rotates. So my workaround was to texture a pupil and link the Planar Proj X&Y to the translate X and Y of a eye control object. So the texture moves relative to the ctrl object.

All looked good until i parented the eye ctrl to the head joint and rotated the head - instead of the pupils remaining still (looking straight at the eye ctrl) it is picking up a translate X&Y from the ctrl and thus rotating the pupil texture - which i dont want!

Im not very good at expressions so bare with me! This is what I have:
Father_eye_L_PlanarProj.rotateY = Father_L_EyeCTRL.translateX
Father_eye_L_PlanarProj.rotateX = Father_L_EyeCTRL.translateY*-1

I almost want to put a "relative" after the translate x or something?!

Hope this makes sense! any help would be appreciated! :headbang:

# 2 05-11-2008 , 07:41 PM
Xander-0's Avatar
Registered User
Join Date: Feb 2005
Location: This Place
Posts: 220
sounds like what you have is a typical 'double parented' situation. What's happening is that not only are the textures being told to rotate from the eye control, they also inherit a rotation from the head control itself. There are a number of ways to fix this. Some things to try;
1) Instead of parenting the eye control to the head, try giving it a point constraint.
2) Add a statement to the expression that subtracts the head's rotation

There's a couple of other things you can do too, although its been a little too long for me (need to get back to working on stuff...)


Book Wise

https://X4nd5r.deviantart.com
# 3 06-11-2008 , 07:31 AM
Registered User
Join Date: Nov 2008
Location: Hampshire, UK
Posts: 2
Thats exactly whats happening - the eye object is a seperate mesh and is parented to the head bone - so the texture is getting a rotate/translate value from any movement from the head. Plus the texture its getting input from the eye look at ctrl since it is moving with the head also - even though i am not directly inputing any translate values into the eye lookat ctrl - so as you say its almost doubling the inputs.

Alas my little knowledge of Mel Script and Expressions has left me stumped.

So if anyone has any ideas how to set up a simple eye lookat rig but using the texture instead of the mesh object i'd be very grateful.

Or if anyone can point me to a site where I can learn a few basic expressions/mel that would be a good start for me!

Many Thanks

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