Tuesday, January 17, 2012

Attaching Buttons on Jacket? 4 ways to do it.

The rivet tool is very useful when attaching buttons on jackets as we saw in the tutorial.  Delano used a classic rivet tool in his course.

Since I have MAYA 2011, it comes with a new tool called Point on Poly constraint.  I was excited to try it out.  Too bad it doesn't do a nice job on keeping the orientation of my object.

As I was searching around, I found 3 tools that serve the same purpose, classic rivet tool, djx rivet tool, and surface attach tool.

So now we have 4 tools that does the same thing!  The question is which one is better.

djRivet tool : use follicles, can do multiple button constraints at once,  with good  UV layout, smoothing the poly is fine.  No need to select components, just select the buttons first, and the jacket, then type hit your shelf button.

rivet tool*1 : use locator, can only do on constraint at a time, has problem after smooth polygon.  select a component, create locator where the component is, parent constraint.

surface attach tool*2:  Feels like the rivet tool, also make a locator on the target object.  Constrain one at a time.  After poly smooth, go select cMuscleSurfAttach node, press fix button.

Point on Poly tool : create problem like above, don't like.

1*."the classic rivet script uses two edges of a mesh to create two curves, which then are lofted together, the resulting NURB is read with a pointOnSurfaceInfo and the parameter UV coords from said node define the position of a locator. He uses the pointOnSurfaceInfo node, along with a modified aim constraint, to achieve proper orientation for the locator so that it follows the orientation of the mesh face."

2*.  Its under animation tab, muscle, bonus rigging , surface attach.  If you can't see muscle menu, check if your muscle plug-in is loaded through plug-in manager.

Monday, January 16, 2012

IK handle offsetting and show all input window error

Problem 1. unwanted IK handle offsetting

When rigging the arm with IK, MAYA generate an IK handle and an effector.  Before you move the effector, make sure that the IK handle's attributes are not modified or locked, and IK handle are not grouped under any other nodes, otherwise when you attempt to move the effector, it will seem like it is locked in space, and the joint will start to offset.

Problem 2.  "All input" window is not showing, maya giving "Error: Object `row 1` not found"

This has to do with the layer that the mesh is sitting on.  Delete the layer, and save the file, reopen, problem solved.

Problem 3. change the order of attributes in MAYA

Sadly, this function is still not in the basic package of MAYA 2011.  This problem dated back in 2003(first question found on the internet).  Luckily we have a script made by comet.  It was developed for MAYA 5, but with a little tweak, it works perfectly in 2011.

This is what you have to do.
1. go download comet attribute editor. http://www.comet-cartoons.com/melscript.php
2. put the script in your script folder, in my case, C:\Users\antarlian\Documents\maya\2011\scripts
3. open it in MAYA script editor(or any other text editor), go to the end of the script, replace the cAE dropToBottom procedure to :

global proc cAE_dropToBottom(string $obj, string $attr)
  // renameAttr ($obj+"."+$attr) ($attr+"TEMPREN") ; // there
    // renameAttr ($obj+"."+$attr+"TEMPREN") ($attr) ; // and back again
    deleteAttr -attribute $attr $obj;

in Maya 2011, renaming an attr doesn't change the order of the attr anymore, that's why it won't work.  But if we delete the attr first, then undo, the attr will pop up at the end of the attr list.

4. run the script,  cometAttrEditor();