Category

Technical Art Applications

Advanced Features

By | Technical Art Applications | No Comments

Along the way I have also been tidying up the rig. Most controls have now had selected attributes locked and hidden. I’ve disabled scaling on almost all joints and some joints are unable to be translated where they are only used for controlling the orientation of a joint. This overall improves usability and readability of the rig and where possible prevents the user from breaking the rig.

I’ve added a few advanced options here and there. First up are the feet which have a number of added attributes such as roll, twist and lift options for the heel and toe. To do this a number of groups were created within each other, each controlling the rotation at an appropriate pivot point. These were then connected to the attributes using the Hypershade connection editor.

While all the functionality is there, the deformation isn’t too great. The skinning isn’t the main problem rather it is the way the joints rotate. I think this is a similar problem to the issue I was having prior to adding IK solvers. Rotating with small values gives the correct result but when you push the rotation the joints move in weird ways. This is something I was unable to correct through troubleshooting and if I had more time would focus on correcting this but I feel this would need to be edited right back at the joints, perhaps their local rotation axis or placement.

In addition the skinning isn’t perfect on the shoes due to the complex mesh and the deformers aren’t perfect either.

I wanted to do a little bit more with my blend shapes. To access them before would require you to open up the blend sheet window and the sliders would be easily accessible from there. This method wasn’t entirely user friendly and would probably be missed as its not obvious they exist. To combat this I’ve added an extra controller that follows the head controller. This new controller holds all the blend shape deformers as attributes which can be edited just as you could with the blend shape window.

I figured I didn’t have the time to look into creating a floating user interface but this would do the job pretty well. In addition to this there is also a face animation camera, accessible through Panels > Perspective > MeryFaceCam which is locked to the head as it moves. The facial animation controller is located conveniently so it can be accessed while using this camera.

I also included an additional variable in the eyes controller which allows you to switch between following the head controller or locking it to the master controller’s world space (with the help of this tutorial). This allows you to move the rig around and the eyes will stay locked in one place. This is something I’d also like to add to the hand controllers if time permits.

Finally I’ve added some functionality in the wrist designed to help it deform better when rotated. Also using the connection editor I fed the rotation from the wrist controller into another joint located within the forearm. As the wrist controller rotates, the forearm joint will rotate 50% of its value. This has proven to work well while skinned.

Skinning – Continued

By | Technical Art Applications | No Comments

Skinning is definitely a time consumer. Not exactly difficult but it requires a lot of focus and tedious detailing to get the whole thing looking great when its animated.

Thankfully I found out about the ‘Mirror Skin Weights’ which has helped out a whole bunch with repetitive tasks. The only area that required editing after mirroring was the other hand as the joints weren’t exactly identical on either side (can’t remember how, think it was to do with pole vectors moving them) but that was sorted too.

The hands themselves have been quite a lot of effort on their own compared to the rig as a whole. On the whole the skinning is fine on them but not perfect. I’ve been unable to correct my weird thumb rotation axis thing and its not looking right at all when bending. Skinning was fine on it although not as easy as on the other fingers but the set driven key I put on it earlier is not working out for it at the moment with the thumb doing some unnatural movement. Set driven key took so long the first time I did it I’m unsure if I’ll be able to attempt a correction on it. Like the feet, rotating small values is fine but pushing it results in unnatural movement.

One thing I am happy with is the skin weights on the jaw. I’ve managed to fix this right up with the lips deforming much smoother and the neck moving better than it was before. I’ve also attached the teeth to the appropriate joint (although for some reason the upper teeth would not show its faces, had to re-import this part of the mesh). Of course there’s always room for improvement, I’d like to add more influences on to the cheek and upper lip to get it looking better.

I also got some decent deformation in the pelvis both where the legs bend and when the spine bends. Not getting volume deformation in the buttocks and making sure the spine didn’t go bumpy required a lot of time with the smooth brush to get a good result.

Most of the recent tweaks have mostly been going around with the add brush and adding low percentage influences on one joint to a neighbouring joint in order to achieve some more realistic movement that there is an influence of one joint to the other.

I would say that I’ve fixed most volume loss issues and each joint deforms as it should. I had to do many test animations to identify problem areas. The wrist skin weights were particularly tricky but having gradient influence from the wrist all the way up the forearm solved this.

The neck and chest didn’t require much editing but the clavicles were hard to work out. I’m not entirely satisfied with the movement the clavicles are giving but I think this is more from the way I connected up the joints and would want to spend time editing this either by adding in corrective joints or adding translation controls into the control shape. More skin weights influence from the upper arm into this area wouldn’t go a miss.

As of right now my biggest concern with the rig is actually with the wrap deformers. I was confident from my earlier testing that it would work fine but this is a problem I wasn’t able to foresee. With wrap deformers on all the necessary objects the rig is considerably slower to manipulate, there’s some noticeable lag. This disappears when the wrapped objects are hidden so I’ve added an attribute to the master controller that turns the visibility of these meshes on and off, just so you are able to take a look at the (naked) rig with no lag issues. It’s frustrating that this was one of the last steps in the rigging process and it was one that had a disappointing result with so few time to correct it. I have tried most of the different settings in the wrap deformer as well as combining meshes and wrapping those but I’m not getting any better results. Unfortunately my slightly laggy rig will have to do as I am unable to get any better results without drastically changing how the clothes are implemented into the rig.

Scripting Tool Progress 2

By | Technical Art Applications | No Comments

I’ve now more or less finished all the features I wanted to include in my tool.

I now have a functionality in the check box for colouring the control shapes. Finding the python command that would change the colour was pretty hard to find but turns it was just an attribute of the object. You first set current_ctrl_shape+”.overrideEnabled” to 1 which allows you to override display settings, then you choose the colour by editing another attribute current_ctrl_shape+”.overrideColour” to a colour index number (13 being red for example).

Initially I had planned to check the joint name and detect if it had a left or right label on it. So jnt_L_arm would be detected as being on the left hand side and therefore be red. I know the code to do this in other code languages but was unable to find it for Python. I did however come up with an alternative to finding out the location of a joint and it was to simply query its translation X value. I originally had it check the translation of the group which only worked sometimes, checking the joint location has been more reliable.

I’ve also coded in the simpler advanced options such as adding in an Orient Constraint and locking translation values. Both of these were handled with a maya command each and just saves the user from searching for these themselves.

Additionally I wanted the ‘general’ control shape to be resized and shaped easily by the user. In order to leave the attributes of the object at zero this is usually done in “hull” mode (right click the object and select hull mode). This was a hard command to find in python as well as its not so obvious.

With the help of Grant Clarke (tutor) we used a method of importing mel scripts that are used by Maya to do some operations.

However while hull mode was opened up, you still had to additionally click the object and select in a menu to edit the CVs. This was just as bothersome as opening hull mode. I wanted the process of creating the control shape to editing it to be instant.

Looking at ‘echo all commands’ I noticed this command appear when you physically click on a “hull mode” selected object: select -r ctrl_root.cv[0:7] To me this seemed like the missing piece in the puzzle and so in python I managed to get it to work in this format: maya.cmds.select(current_ctrl_shape+”.cv[0:7]”)

So the mel script wasn’t needed at all, this simple command does it. Not sure what the [0:7] is all about entirely but individual CVs are referred to as [1] or [2] so the [0:7] probably means all CVs in that object (since there are 8 of them). Oh, perhaps 0:7 means 0 to 7. Well maybe I learned something there. Anyway, I was happy with this functionality as it greatly increases user readability and I managed to work out the second half of the problem without even needing to look up anything on the web.

Scripting Tool Progress

By | Technical Art Applications | No Comments

The scripting tool has been coming along nicely. I’ve coded most of the main features. The tool can now create the two different control shape types and positions them in the correct position. It will also pull in the radius from the input box.

To get the radius to be read properly I had to query the textField and convert the text to a float.

The control shape is also appropriately named using the name from the selected joint following the same procedure as the script we used in class.

I’ve now began adding in the functionality for the optional attributes. For the custom name override when the check box is not selected you are unable to type in the text box. When you check the check box you can type in a custom name for your controller and it will override the automatic name. I debated whether to have the prefix be required or not but decided if the joints are required to be named then the user should be familiar with the prefixes to include it in the name.

I initially managed to get the custom name function working for each individual control shape I was getting a “variable referenced before assigned” error and this was due to the if statement where I was reading the check_name_value, current_ctrl_shape was referenced in both the if and else statements so I had to initialise current_ctrl_shape for it to work.

Skinning

By | Technical Art Applications | No Comments

Now that each limb is rigged I have connected the hierarchy for the the rig. Making sure that each limb goes with the correct body part it should do. After that I began the process of skinning.

(Incoming mini rant, skip to after bullet points for actual important stuff)
I encountered a major problem at this stage which prevented me from moving on to the skinning for a few days. The paint script weights tool did not like me and would refuse to show joint influences on the model. I tried different skinning options on different computers on different versions of different models (also resetting all maya settings). I also messed around with every available option in the tool and checked all display options available to me in the scene. Not only that but even the lists of joints was unresponsive and would sometimes show and sometimes not. I tried troubleshooting this via the internet and it seems like a very common problem but no one method of fixing it. A lot of people had got it working through re-skinning it, or toggling an option on and off but I couldn’t get it to work.

But after a lot of playing around I had discovered my method to fix it which I noted down so I would remember for future uses:

  • ‘Smooth Bind’ with ‘Normalize Weights’ set to ‘Post’
  • Open ‘Paint Skin Weights Tool’
  • Set ‘Normalize Weights’ to ‘Interactive’
  • Select vertex on mesh
  • Select ‘Show influences on the selected verts’

Then the influences would magically appear. The weirdest method ever but if it works I’m not complaining. Unfortunately the colour ramp options were broken for me and would only appear in orange but at least I had something.

The above picture shows the result of the initial skinning, as expected. I have went through the joints and flooded out influences where not needed and fixing any major “you shouldn’t be there”s. By keeping normalise weights on means I was able to avoid any “jumps to the origin” or unexpected movement.

I have done some work on fixing volume issues such as on the knees and a little bit on the spine. The skinning progress as it stands right now is each part of the body is moving with the part of the body it should be and that there are no crazy deformations. Volume loss is still present on the elbows and wrist twist. The feet don’t bend so great right now and more time is needed to fix up the smoothing on the rather detailed mesh.

The head and neck are pretty much fine but the jaw is moving a lot of what it shouldn’t and not deforming naturally. I’ve used a surface soft select to get the lips separated but I’ve not went into any detail fixing it yet.

I’ve tested using wrap deformers on the clothes to make sure they bind and move with the mesh and it seems to work as expected, even covering up some of the bumpy work I’ve got on the spine joint influences (but that’s cheating).

Moving on from here is simply fixing up anything I’ve mentioned so far as well as trying out as many poses as I can to make sure every controller is deforming the mesh correctly.