Question about an old problem with creating face morphs
This is a question about an old issue that I’m just now getting around to asking. I’m using DS 4.8 Pro and Hexagon 2.5. A few years ago I created a face morph for an M4 character. I wanted to make some changes to it so I exported it out of DS as an obj. I hid all nodes except the head and exported it at the default settings as Hexagon with no maps checked. When you do that the Hexagon setting changes to Custom at 100% scale.
Image 1A shows the issue. When I open the exported obj in Hexagon there’s a difference in the Material and Shading Domains list (left column). The top two items on the lists 2_SkinHead and 4_InnerMouth switch places in the Materials list. Everything else in both lists match in their order.
I modified the obj and exported it out of Hexagon as an obj and was curious how those lists would look. So I opened it in Hexagon (right column). In the Material and Shading Domains list 2_SkinHead and 4_InnerMouth match and are no longer switched.
I brought the modified obj into DAZ with Morph Loader Pro (Image 1B) and applied it to a newly opened M4 figure and when I dialed the morph the face morph was created without any problems but the 2_SkinHead and 4_InnerMouth surfaces distorted.
Is this what is referred to as the order of the vertices have been changed? I never experienced this problem with creating face morphs until I finally updated DS to 4.8 some time ago. Is it a problem with either DS or Hexagon? Or is it that 4.8 and newer simply aren’t playing nice with M4 anymore?
Comments
Load the distorted one in D/S and shoot it over the bridge to Hexagon. Check the UVmaps, it could be that they were zapped.
Morphs usually take better if one makes full use of the Bridge.
Yes.
This is a problem in many different types of 3D applications. Here, it's very likely that Hexagon is the culprit. I don't use DS or the bridge. However, I can help you fix this problem.
First, you'll need a copy of UVMapper Classic: https://www.uvmapper.com/downloads.html (Free)
What you're going to do is take the original model, make what is called a ".uvs" file from it, which contains its materials, groups and vertice information, and then you are going to apply that to the corrupted model/morph. You can also use a copy of the original object group and apply its uvs/groups/vert info to the new object. It's just a matter of which you want to reference. While both uvs and original mesh group will work, if you encounter an issue, make sure you try both methods. (The only issue you will likley encounter is either a failure or an "incompatible vertice count" sort of message from UVMapper.
Keep in mind that this will not work with multiple groups. You can only do this for one group at a time. Ideally, you will export each group from DS as a wavefront object file and keep them by themselves, named exactly as they should be, in a reference directory. Then, you can just go there whenever you need to correct the vertice order for a particular group.
PS - This method does NOT depend on anything other than the original reference object geometry or a uvs file generated from it. If, for instance, you use a morphed object group, using that as a reference will still work, just as long as it has the correct vertice order. (The actual position of the vertices isn't used, just their order, group assignment, material,etc.)
1) Load up your M4 figure in DS. Zero it. Export only the "head" group as a wavefront object and save it in an easy to find directory. (ie:3d/figure work/M4 reference object/groupname.obj)
2) Start UVMapper. Import your head morph group. Only one, likely the head group object.
3) (I don't have it in front of me, so from memory) Select "Import uvs" and then navigate to your original m4 reference object and load it.
4) Save your morphed head with its new uvs. Make sure to leave all the default options checked, but you can uncheck "export normals."
5) If you've done it right and the problem was, indeed, a vertice order problem, then it will be fixed. IF it wasn't, it will not be fixed.. HOWEVER - There are times when during morphs/extreme morph creation, vertices do get so wonked up that this process will not recover their original winding order.
6) If 5 didn't work, then start UVMapper, load up the original M4 head mesh reference object you exported, earlier, and then you want to choose to Export its uvs. This will generate a *.uvs file. Repeat the above steps and then load the morphed head object and apply this .uvs file to it rather than the obj file. That "might" work.
7) For every group that has been morphed, you can use this method to correct the vertice order. It must be done group-by-group, individually. It isn't guarranteed, but it is pretty darn foolproof.
Lastly, there is a method using an old javascript application called "Compose." It involves a much more initial complicated step, but then it can be eaisly used and save you a lot of time, since you can reorder vertices across multiple groups using this method. The program is free. IIRC, it is "John Wind's Compose" utility. It's old, but it still works. (I have it on another 'puter.) You may be able to find it archived somewhere.
PS - You can also use Blender to try to do this, more or less, but it would be more complex and I don't think Blender can reorder vertices as easily as this method.
Edit-add - You may need to reorder the neck group, as well. In general, you'll usually find the head or neck group with reordered verts, but not both. Weirdly, eyes seem almost immune to this. Collar groups, less so. Chest groups also can frequently have this issue as well as one or both thighs. Fingers/hands... etc. So, you see, if you're doing a full body morph in another app, you may have to import group-by-group corrected morphs, which makes this process tedious. But, it can and will work.
PPS: :)
This shouldn't be caused by the DS bridge and Hex as I don't think it relies on Hex to actually create a save file which would include new vertice orders. IOW - It should preserve those and take the object right out of the workspace. BUT, it wouldn't surprise me if, due to DAZ's newer figure formats, they wouldn't seek to preserve Gen 4 functionality in DS/Hex bridge. You'll have to check around on that, yourself. I doubt it's the case, but ya never know.