Avatar Heads

Building a complete Avatar Head is the most complex task for a creator in IMVU.
For the purposes of this tutorial, we assume you have read:
Mesh Introduction Tutorial
Mapping Materials Tutorial
Morph Targets Tutorial
Weighting in Skin Tutorial

Corrupt File
While its true that building a Head is hard because 1) you need to know how to model fairly well, 2) you need to know how to use Skin fairly well, and 3) you need to have a deep understanding of how to make Morph Targets, the hardest part of making a Head is file corruption. Your file may not become corrupt the first time, or even the second time you build a Head, but eventually it may happen due to bugs in 3dsMax.A MAX file can become when you make multiple copies of a Single Mesh and perform the same actions on those files. Spirit - a well know IMVU Creator - has the following suggestions: In 3ds MAX, instead of moving your copies out from the original location by holding down Shift and then dragging, make your base copy from your Parent Mesh as follows: 1. Select the Parent Mesh 2. Hold down the Shift key and click on the Parent Mesh 3. In the Object Options dialog that appears, make sure that copy is selected and instance is unselected 4. Name the copy you want to make Base Copy 5. In the same way, clone the Base Copy and name it your Morph 6. Once you have cloned your Morph model, hide the rest of the objects so you can work with your Morph Model 7. Follow the Morph tutorial

Get the Example Head Files
To build a new Head, you should begin with an Avatar that is positioned in the 'Weighting Pose' and that also has all of the Morph Targets in the file. This, of course, means that the files are much larger than the Master Weighting Poses. Files for both the Female and Male heads are supplied in the IMVU Unified Installer. The female file also contains product61995.cfl, example Female Head Textures, and the Master Skeleton file. The Male file also contains product59086.cfl, example Male Head Textures and the Master Skeleton file. All of these files will come in handy later when using an Editor in Create Mode.

Example Head Contents
The Example 3D Head files contain everything necessary to Export a functional, Animating Head Mesh. This includes a Master Head Mesh, Morph Targets, the Avatar Skeleton and Default Body Meshes. NOTE: Save these files with a new name as you may need to merge facets of the original example 3D Head files into your new Head file if a mistake is made.
NOTE: If your final Head product's file size is too big, it is unlikely that your potential customer will purchase and download it. It is good practice to try to keep the texture size, Vertex/Face Count of your Meshes and Animation length as small as possible.

Build Mesh - Geometric Complexity
A Head can be as simple as one Polygon, if you so choose. It can also contain as many or as few Morph Targets as you like. The IMVU Heads supplied can be pushed and pulled to become a wide variety of Head shapes while still maintaining the same Mapping across problem areas (like Eyes and Lips). By using the supplied Head, you also get the benefit of knowing that other products like Skin, Eyes, and Eyebrows will work on your Head too.

Build Mesh - Parents and Children
The Mesh that actually gets Texture Mapped, Weighted to the Skeleton and Exported is the 'Parent'. All of the Morph Targets are called 'Children' in that they get linked to the Parent in order to be included in the Mesh Export.

Build Mesh - Adding or removing Vertices
A Morph Target is an EXACT DUPLICATE of your original Mesh but with some Vertices pushed and pulled into a new location (like, a Smile or Blink). This means that adding or removing Vertices (even just one Vertex) will change your copied Mesh from a Morph Target to just another Mesh. Likewise, adding or removing Geometry from the Parent will render all of your Morphs useless. If you build a Mesh and then build out all of the Morphs and THEN realize that you need one more Vertex to get the shape you want on the Morph,you should realize that you will have to rebuild all of your Morphs from scratch.
Build Mesh - Match the Neck
If you are building a Head that is meant to blend seamlessly into the tens of thousands of Upper Body products in the catalog, you must match the Neck Vertex positions exactly to those of the Upper Body Mesh supplied in the Example Head file.
To do this, just click the move icon and turn on the Snap Tool. Then, when you click on a Vertex and move it around, it will try to snap to another, nearby Vertex. In this manner, you can move each Neck Vertex in your Head Mesh *near* the appropriate Neck Vertex in the Body Mesh and it will 'snap' to the exact same 3D space as another Vertex.

Build Mesh - Oversized Heads
The default Avatar Heads in IMVU are of an enlarged, Anime style. All of the accessories and Hairstyles in the catalog have been built to fit these default Heads. This adds a level of complexity to those of you who plan on making a Head that is meant to work with those existing products.Basically, in MAX, your Head will look enormous in order for it to fit the original Hair, Accessories and Neck. This is OK, though, as you will be able to reduce (or enlarge) the size of the Head later in an Editor in Create Mode. You can also change its depth so that a squat face in MAX can end up looking normal in the Editor. In 3dsMAX, an oversized Head with no penetration on hair or accessories = good.

Build Mesh - Mesh Scale
It is really important that you understand that you can change the size and depth of your Head file later when using the Preveiwer. If you want the Head to work with existing Hair and Head-Accessory products, your Head will need to fit within the Glasses and Hair supplied in the example Head files. Sometimes, this means the Head Mesh file can look squished (from front to back.)

To learn more about this, please consult the Mesh Scale Tutorial.

Build Mesh - Half a Head
It is important that you keep symmetry when building your head.
Start with half a Head and get that half looking the way you want. Add the Eyes, Eyelids, Eyebrows, Lips, Teeth, Tongue, Cheeks, and Ears. Get all of your Material IDs set up and your Texture Mapping done correctly.

Build Mesh - Separate Eyes and Eyebrows
It is important to note that it is MUCH easier to Animate the Eyes and Eyebrows if they are Geometrically separate from the rest of the Head.

This does not mean that they should be separate pieces of Geometry (ie - different objects in the scene.) Rather, no Vertex of an Eye should be connected to any part of the rest of the Head. This allows you to more easily move the Eyes around within the Eye Socket when building your Morphs later.

Build Mesh - Anticipate Morphing
One of the biggest mistakes that first time Head builders make is not giving themselves enough Geometry in areas of the face that are going to Move/Animate later on.

For example, when building the Eyelids, you can safely assume that they will be made to blink. This means that they need enough Geometry to get around the full, rounded shape of the Eye.
The areas of the Head that require the most Geometry are the Eyes, Mouth, Nose and Cheeks. By far, the highest concentration of Vertices is around the Mmouth because it is meant to take on a myriad of emotional shapes.

Build Mesh - Cheapskate
An Avatar Head is the most expensive part of the Avatar from a file size, download and rendering perspective. This is because it typically has the most complex Geometry as well as Morph Targets. Each Morph Target makes your final, Exported Mesh .xmf file a little larger.

For example, some IMVU Heads have 72 Morph Targets while others have 30+. An Avatar built with the larger number of Morphs is roughly 300k while an Avatar built with the smaller number of Morphs is roughly 200k.

The point is that you need to be careful that your Head mesh is not overly complex. Always err on the side of fewer Polygons.

Build Mesh - Aide: Plaid Material
IMVU users expect their Skin Texture products to work perfectly across all clothing Meshes. When their Skin Texture products do not work perfectly, they get upset, leave bad reviews and spread the word that your products are unreliable. So, please err on the side of delighting your customers and use the Texture Mapping IMVU has already built for you.

To the left is the 256x256 plaid texture we use to make sure that our Mapping is perfect. When this Texture is applied to the Avatar Head in MAX, the horizontal and vertical lines are drawn as straight as possible. This should allow you to more easily see how the Skin on your new Mesh is Mapped and, more importantly, whether or not it matches what is on the Master Meshes.

Build Mesh - Material IDs and Texture Mapping
The Avatar head Material IDs are:

Material 2 = Head (skin)
Material 3 = Eyes
Material 4 = Hair
Material 5 = Eyelashes
Material 6 = Eyebrows

When a Polygon in your Head is given a Material ID of 2, then that Polygon will display the Skin Texture in IMVU. This is really handy for those of you who are building Heads that are meant to work with existing Skin, Eye and Eyebrow products.
NOTE: The Material ID integer in MAX is different that the integer in Cal3D (the system that IMVU uses to create products). Specifically, MAX starts its IDs at the number '1' while Cal3D starts its IDs at the number '0'. This means that a Polygon with a material ID of '1' in MAX is actually '0' in Create Mode. To handle this, we rely on the name of the Material to dictate what ID it is. That is is why we use the following naming convention for Materials: materialName [0]
To learn more about Material naming conventions, please consult the Texture Mapping Tutorial.

Build Mesh - Copy Initial Half
Once you have your Half-Head built and Mapped the way you want it, its time to make the other side.

First, select your Mesh and then Shift+drag. This will bring up the Clone Part of Mesh dialog box. Choose to Clone to Object, name it whatever you want and click OK.

Build Mesh - Mirror
With your copy selected, click the Mirror button along the top panel in 3dsMAX.
This will launch the Mirror: Screen Coordinates dialog box. Since you have built, say, the right side of a face and want to now create the left side, you want to mirror the copy along the X axis only. Also, make sure that 'No Clone' is selected.

Then, click OK and the copy will mirror your mesh.

Build Mesh - Select Material ID [2] of Mirrored Mesh
You must now flip the Mapping on the flesh of the face.

In the Material ID section, select all Polygons that have been labeled as material ID [2].

REMEMBER: Material [2] means you are actually selecting Material ID 3 in 3dsMAX.
Build Mesh - Unwrap UVW &Flip Mapping
With the Face Mapping Verts selected, set the Mirror Mapping tool to Horizontal and click it. This will flip the Mapping for the selected mapping Verts.

Now, set the Move Tool to Horiz only and then drag all coordinates far off Map to the left. You will put them all together later. The important thing is to get all of the Mapping Flipped on the Mirrored Head so that users can customize both sides of the face.

Follow the same process for the Ears and Tongue. You can leave the Neck, Teeth and Inner Mouth alone.

Note: Eye and Eyebrow Mapping do not need to be Flipped.

Build Mesh - Snapping
With your copy still selected, click the Move Tool and then turn on the Snaps Toggle.

Now, select an Edge Vertex on your copy and move it to the Matching Edge Vertex of the original. It should snap perfectly into place.

Build Mesh - Attach
Now select your Parent Head. Then, in the Edit Geometry drop down, enter 'Attach' mode. Then, click on the copy to make the two Meshes into one.

REMEMBER: Once you attach your copy, please make sure to EXIT attach mode. Otherwise, you could end up unneccessarily attaching other objects in the scene to your Head Mesh.

Build Mesh - Select
With the two halves now one, it is time to make sure that all of the Verts along the center seam are actually in a perfectly straight, vertical line. This is so you can weld them in the next step.

Select the Head and enter Edit Vertex mode. Make sure you are looking at the Head from the Front view and then drag along the very center of the Head. This will make sure that you get all of the Vertices on the inside of the Mesh as well as on the outside.

Build Mesh - Weld
With all of the Center Verts selected, click the Weld: Selected button. This will make all of the duplicate Vertices disappear and give you one smooth Mesh to work with.If you didn't do this step, then, no matter what you did, your Head would look like it had a seam down the center of its face. This is because the smoothing groups between the two Heads could not be made to be the same.

Build Mesh - Wrap it up
Now that you have one solid Mesh for a Head, it is time to wrap it all up. The first step is to go through the material ID [2]/3 selection process again and get the Mapping straightened out.

Select the Mapping you placed well out of the way and move it into place. When the Center Boundary Verts are in place, you can Target Weld them using the Mapping Vert Target Weld Tool. This will make sure that the Mapping across the Forehead, Nose, Lips and Chin is seamless.

With the Mapping done, you can move on to Weighting.
Test #1 - Weight & Export
Once you have a finished Head Mesh complete with proper Material IDs and Texture Mapping, it is time to test whether that Head, without any Morph Targets, works in IMVU. To do this, the Head needs to be Weighted using Skin. To learn more about how to do this, please consult the Weighting in Skin Tutorial.

Once the Head is Weighted, you can Export it as an .xmf as usual. To learn more about Exporting .xmf files, please consult the Exporting the Mesh - .xmf Tutorial.

As a reminder, this tutorial assumes you are building a new Head for use on the IMVU Avatar. This means that you can use the Skeleton .xsf file supplied with the Master Weighting files when Exporting your Mesh .xmf file.

Test #1 - Create Mode
Open Create Mode and choose to derive from an IMVU head product like Product 59412 for females or Product 59087 for males.

To learn more about Create Mode, please consult the Create Mode Introduction.

With a Create Mode Editor open, click on the Meshes tab and then browse to your newly Exported xmf Asset. Click the Apply Changes button and verify that:

1. Your Head Mesh actually appears on the Avatar (this lets you know that there is no issue with the Mesh itself).
2. Your Head Mesh moves with the Head Bone (this tells you your Weighting is correct).
3. The correct Textures appear on your Head (this tells you your Mapping/Material IDs are correct).
If any of the three above are not met, you need to go back and resolve the issue. If things look good, then you know your base Head works great and it is time to add Morphs.

Morph Basics
To learn the basics of Building Morphs for any product, please consult the Morph Targets Tutorial.

Below are a few Avatar Head-specific Morph tips.

As far as IMVU is concerned, a good set of Morphs = a set of Morphs that:

a) Don't penetrate or tear pieces of the face when played back and
b) clearly express the emotion of the character when their Head takes up less than an inch on screen.

Morph Naming Convention
Morph Targets in IMVU use a naming convention that dictates what kind of Morph they are. This naming convention must be used or your Morphs will not play back in IMVU.

An example of a properly named Morph Target is leftBlink.Clamped where the .Clamped suffix is the Morph type. The prefix of the name can be anything you like.

Here is a breakdown of what the four Morph types are and what they mean:

.Clamped - allows multiple Morph Animations to affect the channel but clamps the sum of their effects to 100%.
.Averaged - allows multiple Morph Animations to affect the channel, averages the result.
.Exclusive - allows only one Morph Animations (the most recent one applied) to affect the channel, no cap on value (i.e. allows values greater than 100%).
.Additive - allows multiple Animations to affect the channel, values are added together.

For the purposes of this tutorial, we will name our Morph Target 'Morph.Exclusive'.

Avatar Head Morph Names
Below is the full list of Morph names IMVU uses in its base Avatar heads. There are 79 of them. These are the morph names available to you if you want to make a Morph Animation using the IMVU base Avatar heads:

1. blink.Left.Lower.Clamped
2. blink.Left.Upper.Clamped
3. blink.Right.Lower.Clamped
4. blink.Right.Upper.Clamped
5. blink.Wide.Left.Average
6. blink.Wide.Right.Average
7. eyebrow.Left.Angry.Average
8. eyebrow.Left.Down.Average
9. eyebrows.Left.Center.Up.Average
10. eyebrows.Left.In.Average
11. eyebrows.Left.Mad.Average
12. eyebrows.Left.OuterDown.Average
13. eyebrows.Left.OuterUp.Average
14. eyebrows.Left.Sad.Average
15. eyebrows.Left.Up.Average

16. eyebrow.Right.Angry.Average
17. eyebrow.Right.Down.Average
18. eyebrows.Right.Center.Up.Average
19. eyebrows.Right.In.Average
20. eyebrows.Right.Mad.Average
21. eyebrows.Right.OuterDown.Average
22. eyebrows.Right.OuterUp.Average
23. eyebrows.Right.Sad.Average
24. eyebrows.Right.Up.Average

25. Eyes.Bugged.Left.Average
26. Eyes.Bugged.Right.Average
27. Eyes.POP.Left.Average
28. Eyes.POP.Right.Average
29. Eyes.Scale.Left.Average
30. Eyes.Scale.Right.Average

31. left.Eye.Down.Clamped
32. left.Eye.Left.Clamped
33. left.Eye.Right.Clamped
34. left.Eye.Up.Clamped

35. mouth.BigSmile.Exclusive
36. mouth.BigSmileLEFT.Exclusive
37. mouth.BigSmileRIGHT.Exclusive
38. mouth.Bite.Left.Exclusive
39. mouth.Bite.Right.Exclusive
40. mouth.CheekLEFT.Exclusive
41. mouth.CheekRIGHT.Exclusive
42. mouth.Cheeks.Exclusive
43. mouth.Down.Exclusive
44. mouth.F.Exclusive
45. mouth.Frown.Exclusive
46. mouth.FrownLEFT.Exclusive
47. mouth.FrownRIGHT.Exclusive

48. mouth.Grin.Exclusive
49. mouth.GrinLeft.Exclusive
50. mouth.GrinRight.Exclusive
51. mouth.JawDown.Exclusive
52. mouth.LeftSmirk.Exclusive
53. mouth.RightSmirk.Exclusive
54. mouth.MadLip.Exclusive
55. mouth.MadLipLEFT.Exclusive
56. mouth.MadLipRIGHT.Exclusive
57. mouth.Narrow.Exclusive
58. mouth.NarrowLeft.Exclusive
59. mouth.NarrowRight.Exclusive

60. mouth.OH.Exclusive
61. mouth.Open.Exclusive
62. mouth.Pucker.Exclusive
63. mouth.Scream.Exclusive
64. mouth.Smile.Exclusive
65. mouth.SmileLeft.Exclusive
66. mouth.SmileRight.Exclusive
67. mouth.TongueDown.Exclusive
68. mouth.TongueLEFT.Exclusive
69. mouth.TongueOut.Exclusive
70. mouth.TongueRIGHT.Exclusive
71. mouth.TongueTHIN.Exclusive
72. mouth.TongueUp.Exclusive

73. mouth.Up.Exclusive
74. mouth.Wide.Exclusive
75. mouth.WideLeft.Exclusive
76. mouth.WideRight.Exclusive

77. nose.Flare.Exclusive
78. nose.FlareLeft.Exclusive
79. nose.FlareRight.Exclusive
80. nose.Long.Exclusive

81. right.Eye.Down.Clamped
82. right.Eye.Left.Clamped
83. right.Eye.Right.Clamped
84. right.Eye.Up.Clamped

There is an 85th Morph Target, Face.Average, but that is not used for Animation. To learn more about how to utilize this Morph Target, please consult the Avatar Heads Tutorial.

Blink Morphs
The Blinks are very important. Along with the Eye Morphs, they imply the most sentience as well as help convey a large range of emotion. Here are some things to keep in mind when building Blink Morphs.

Use morphs on your morphs - Build an extra copy of the Head and make one Eye Blink completely (both lids). For this example, we'll use the left Eye Blinks. After you've made a Head with one Eye's lids fully closed, select your Left Blink Lower Mesh, go into Vertex Mode and select only the Vertices of the Lower Lid.

Then, apply a Morpher Modifier to the Left Blink Lower Mesh. After the Morpher is applied, you will see a list of Target spots that say 'empty'. Right click on the top one and select 'choose from scene'. Then, click on the extra copy. When you do this, the name of your extra copy will appear in the Morpher list. Drag the slider of this entry all the way to 100% and you will see the lower lid of your mesh morph to the position of the Morph Target.

When you have the shape exactly how you want it, collapse the stack on your Left Blink Lower Mesh in order to reduce file size and make it possible to use this Mesh as a Target for your Master Head later. Follow the same process for the Upper Lid (of course, selecting only the Upper Lid Vertices on your left Eye Upper Mesh).

For each of the four Blink Morphs, move the Eyeballs back into their Sockets a little so that the Eyeballs don't penetrate the Eyelids as they Animate. Not too far, though or the eyes will look sunken.

Eye Morphs
The Eye Morphs are tricky for two reasons. They CAN contain bits from other Morphs to make the Avatar feel more alive. They also need to be tweaked to not look Cross Eyed in IMVU.

The IMVU avatars move their Eyes because our code tells them what Morphs to play, at what percentage, for how long and when. Our system has been built to accommodate our first two Avatar Heads: the Male and Female Anime Heads.

As is true with humans, the left and right Eye movements are not necessarily the same amount of movement from the default position. When the left Eye looks left, it turns to the left a little more than when the right Eye turns left. The amount of adjustment is miniscule but can make the Eyes look less Cross Eyed at run time.

We have two tricks we use on our Eye Morphs to help the Avatars look more alive. The first is that we raise the Eyebrow a bit on both the Right Eye Right and Left Eye Left Morphs. This helps give the illusion that the Eyes lead the Head before the Head turns. We also lower the Upper Lids on both Eye Down Morphs - so they don't look odd when the Avatar looks down.

Mouth Morphs
The Mouth Morphs are the hardest to build and hardest to get right because they affect the most Geometry. Additionally, it is likely that you will get mesh penetration when several Mouth Morphs are played if your Morphs are not built correctly.

Give Yourself Some Room
Considering the close proximity (and the likelihood of penetration) of the Tongue, Teeth, and Cheeks, it is a good idea to pull the Teeth and Tongue further into the mouth for the Open Mouth Morphs.

Fill the Mouth
Although this contradicts the above recommendation, when building the Smile Morph, you ought to fill the Mouth with teeth so the smile will look recognizably like a Smile when the Head is only an inch tall on screen.

One Side First
Using the Mirror/Align/Snap process described above for building Blink Morphs, you can build out one side of your face to save time. Then, make a copy of the one-sided smile or frown or etc - Mirror it, Align it to your Master Smile, Frown, etc - and then use the Snap Tool to move the Verts of the unedited side of the face into place. You will have to tweak the center line of Verts, of course, but you will end up with a symmetrical Smile, Frown, etc.

Morph Groups
You can see in the example Head files that we use a standard morph set up. You can have your file set up any way you like. However, we recommend this:

1. Separate the Eyes, Eyebrows, Nose, Blink, and Mouth Morphs into separate groups.
2. At the same time, keep your face.average Morph close to the Parent Head Mesh so it is easier to see how different from the Parent your changes are.

Before you go diving into making a whole new Head from scratch, there is a much simpler way to build a new Head.
By simply moving some verts around on this Morph Target, you can build a new, fully Animated Head that works with all existing Skin, Eyebrow and Eye products in the IMVU catalog.
Sometimes, you don't want to take the time to build an entire Morph Set just to get a new Head into IMVU. If you just want to test how a Head shape or just want to make a quick Head, you can do so by just changing the face.Average Morph Target.

Just make your changes to face.Average, select the Head and then Export a new XMF. Load this XMF into your derived product and hit apply changes to see a very different Avatar!

Test Combinatorics
The real trick to building a believable Head with Morph Targets is to make sure that all of the Morph Targets work well together. Do the Teeth poke through the Cheek when the Avatar Smiles? What about when the Avatar Smiles and Winks? and Puckers? and Looks Angry? Arguably, this is the longest phase of building a Head as you really want to avoid ugly penetration at all costs in your final Head product.

Hint: Heads with lots of Geometric penetration sell poorly and are reviewed unfavorably.

To learn more about loading Morph Targets into a Morpher Modifier, please consult the Morph Targets Tutorial.

If there is any penetration, you need to adjust the Morph Targets themselves and then reload and test the Morphs until you get it just right.

If all of your Morphs work together, it is time to Link them to the Parent. Click the 'Select and Link' Tool, drag over all of the Morphs and then click on the Parent Head Mesh. In Wireframe Mode, you will see the Parent Head Mesh Blink White to let you know the Link was successful.
NOTE: to make sure you Link your Morphs to the right Mesh, it's a good idea to hide the Hair, Glasses and Earrings first.

Then, just select all of the Morphs and Link them to the Parent Head. To learn more about Linking, please consult the Bone Parenting Tutorial.

To verify that the Linking worked, click the Select by Name button to bring up the Hierarchy dialog box.
The hierarchy ought to have the Head on top with all of the Morphs indented underneath it as shown below.

Export - Test Animation
You can Export and test your .xmf as many times as you like. Typically after every 'set' of Morphs is completed.

For example, test the Head when the Eyebrows are built, then when the Blinks are built, then when the Mouths are built, etc.
NOTE: It takes a long time to Export a head with 85 Morph Targets Linked to it so it's a good idea to leave the computer to work.
When all of the morphs are done and your Head file is working in a Create Mode Editor - save it first then submit it.
© 2018 IMVU All rights reserved