Heads v 1.0
In IMVU, you can replace the default avatar head with a head of your own design. You can choose to make these heads as big or as small as you like and the heads can be anything your imagination can conjure up.
That said, building a head is one of the most challenging things you can build in the IMVU art pipeline. The good news? You CAN build them. 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 Physique 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 [insert errie music here. Note, music may contain someone playing a saw].
Your file may not become corrupt the first time, or even the second time you build a head. However, please know that a corrupt head file is waiting in the shadows and will strike you when you can least afford it. Best to keep whistling ‘Singin’ in the rain’ while you work. This confuses the dreaded corrupt file.
A MAX file can become corrupted for a number of reasons. One of the sure fire ways to get a corrupt file is to make multiple copies of a single mesh and perform the same actions on those files – which you will no doubt do in order to save yourself gobs of production time. I am guilty of this same act and, sometimes, most of the time, it actually works. However, sometimes, I collapse the stack on a bunch of meshes and….my file size rises inexplicably each time I save…eventually making MAX unusable and making the file un-openable...and, in some very rare cases, killing the fan on your graphics card! YIKES!
So, now that you know what you are getting into, read on, intrepid soul…
This document assumes that you are very familiar with the IMVU art path as well as how to use a 3D modeling program.
Chapter Uno: Building the Mesh and Materials
1.a Retrieve the example 3D Head file
For the purposes of this document, we will be using 3DS MAX as the default 3D editing program. Start MAX and open one of the example 3D Heads. The Example 3D Heads can be found in either the ExampleFemaleHead.zip or ExampleMaleHead.zip download on our developer site at https://www.imvu.com/catalog/web_developer_tools.php?section=Developers
The female .zip file also contains product61995.cfl, example female head textures, and the master skeleton file. The male .zip 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 the Previewer.
You will most likely use the skeletal hierarchy found within this MAX file. Considering that completely new avatar products will not work across all Scenes, Rooms, Head and Action menu items, we will not be covering how to build your own entire avatar from scratch in this document. Heads is heads.
1.b 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: We at IMVU, inc. do not limit you in how large any particular piece of your Head asset can be. We do, however, limit the overall size of your final CFL product file to 2mgs (WHICH IS HUGE). Download and runtime size is an issue that should be kept in mind whenever designing for IMVU. If your Head’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 down to the bare minimum. There really is no reason to have a 256x256 texture on a tiny facet of your Scene: it just won’t be seen. In fact, we have found that the smaller the texture, the BETTER it looks in IMVU. Go figure.
Fig. 1.1 – Newly opened female head file in MAX (with Matt’s custom colors)
1.c 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.
1.d 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.
1.e Adding or removing vertices – your friend?
Morphs are interesting creatures in that they are pretty much a morph target or not. 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. Vice versa, adding or removing geometry from the parent will render all of your morphs useless.
Said another way, 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.
Do not be afraid of this, however, as it is bound to happen. Haha – one of the reasons making heads can be so hard is because it requires patience.
1.f Match the neck EXACTLY
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. This will, as they say, ‘snap’ the vertex to the exact same 3D space as another vertex. Use the snap tool (image).
Fig. 1.2 – Click the move button and then click the Snaps Toggle to snap verts.
1.g Match hair and accessories
We include a pair of glasses, a hairstyle and a pair of earrings in each of the example Head files. These can be used as guides if you intend to make a head that people can use with all of their existing accessories. There are three important things to keep in mind if you are attempting to build a head in this manner:
First, you must leave the entire cranium alone so that it works with all hairstyles. By ‘works’, I mean that it does not penetrate through the hair in any location. When the head penetrates through the hair in this manner, it really draws attention and makes the avs look “not so swell”.
Second, you must make sure that the bridge of the nose stays in exactly the same position. This way, glasses won’t penetrate through your avatar’s face.
At the same time, the ears should simply not be touched. Of course, some folks are going to make elven ears and such, but please know that some ear accessories will not work. So, although some risks are more negligible than others, the position of the ears on the head should not change as glasses and earrings would either penetrate the ear geometry or float around it – kinda dorky.
1.h Big heads are not just for egomaniacs
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 more human head. 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 the Previewer. You can also change its depth (image) so that a squat face in MAX can end up looking normal in the Previewer.
Fig. 1.3 – Oversize head with no penetration on hair or accessories = good
1.i Material IDs and mapping
The original IMVU heads come with three materials applied to them: skin, eyes, and eyebrows. If you are building a head that is meant to work with the existing skin, eye and eyebrow products in the catalog, Please stick to the material Ids provided in the MAX file. That way, you won’t have to export new material (xrf) files for your new head – all of the textures will just work!
If you are using the head provided in the Example files as a starting point for your new head, you will need to remap the textures. This is easy. Once you’re happy with the geometry, select the faces of the head you wish to fix the mapping on and then add an ‘Unwrap UVW’ modifier to it in the ‘Modify’ stack on the right hand side of the screen. When you do, an edit button will appear under the ‘Parameters’ section. Click that edit button and the Edit UVWs screen will pop up. Just select points or groups of points and move them around as you like. You can zoom in as close as you like to make sure the textures line up right.
NOTE: I typically have the Edit UVWs window options customized to allow me to see the adjustments I make in real time on the mesh. SUPER handy. Below is a shot of all of my unwrap settings.
Fig. 1.4 – Unwrap UVW options menu – Matt’s settings
1.J Mapping Your Mesh
Please note, IMVU supplies you with a perfectly working sub-material to use with the heads. This sub-material contains skin, eyes, and eyebrows already set up for you. Although you may create your own mutli-subs for your head, IMVU recommends you use the embedded ones for your first pass at head building.
Texture mapping in any 3D program is an art all its own. However, there are a few IMVU specific things that you ought to know before you can export. First up, when you are ready to export, you are meant to have only one (1) material that is a multi-sub material. Within the multi-sub material, you may have as many material ids as you like.
1.J.1 One Multi-Sub Material
If you are using MAX, you may only have one material on your model. This material can contain as many sub-materials as you like and can therefore be a “Multi-Sub” material. If you are using another 3D program, it is likely that you will have to have separate top level materials. This may result in your needing to have more meshes than described in this document.
1.J.2 Multi-Sub Material naming convention
What follows is from the IMVU Developers forum:
“When creating your materials for IMVU products, you must follow a simple numerical naming convention in order for your textures to show up in the previewer. Each material name must contain a bracketed number at the end of the name.
For example, FrogTexture [2]
The number contained in the brackets is always one number less than the material index in MAX. Therefore, every time you have a material in index 1 in MAX, that material's name must contain [0] at the end of its name. If the index is 6, the convention is [5]. If the material is 10, the convention is [9] and so on. It is actually pretty easy once you know what to do. It is also easy to forget if you've never done it before. Very easy.“ (see fig 1.3)
Another thing to consider when naming your sub-materials is that they need to be consecutively numbered. You cannot have four sub-materials number [0], [2], [7], [22]. If you have four sub-materials, those materials must be numbered [0], [1], [2], [3]. Otherwise, you will end up with a product that will eventually not load. (see fig 1.3)
fig 1.5 – Example of Material Editor and Sub-Material layout from MAX
1.J.3 Alpha
You can use both Cutout and Alpha blending in IMVU.
1.J.4 HIGHLY Recommended Texture Guidelines
Although we have said it many times, IMVU imposes no budget on your texture usage but we do recommend the following guidelines to providing your customers with a decent IMVU experience.
· All textures are required to be powers of 2 along a given side.
· No texture should be greater than 512x512 pixels (this is actually a very helpful guideline as the larger your texture, the worse it looks in the IMVU window. This is due to IMVU having to cram all of your texture information into just a few pixels. Better to play it safe and keep your texture small and, surprisingly, more legible)