Tongue4 missing after Import FACS Units

Issue #1033 resolved
Rakete created an issue

I have custom properties for tongue01-03 on the DAZ armature after importing FACS units, but no tongue04 property. Those properties are driven by the Tongue Tip Bend slider, and therefore the the tongue bending movement is incorrect as it won’t affect the tongue04 bone.

Comments (10)

  1. Thomas Larsson repo owner

    In DS, a bone has both a name and an ID. They are usually the same or at least related, but for the G8F tongue bones the relation is very confusing.

    ID           name
    tongueBase   tongue01
    tongue01     tongue02
    tongue02     tongue03
    tongue03     tongue04
    

    The importer uses the names as bone names, but the morph formulas apparently use the ids. The tongue tip bend morph affects the bones with IDs tongue02 and tongue03, which should be the bones tongue03 and tongue04. But the plugin was not aware of this.

    Naming the Blender bones with the daz IDs would solve this particular issue, but it cannot be done because a lot of other things would break instead. I have an idea how to deal with this, but it will take a while to work it out.

  2. Thomas Larsson repo owner

    Looking at the code I realize that the plugin already did handle both bone names and IDs in formulas, but it got confused if they refer to different bones. The issue should be resolved in the last commit, but some cleanup remains.

  3. Alessandro Padovani

    That’s not what I get for G8F. If I save a G8F figure then in the duf file I have id = “tongue01” and name = “tongue01” and label = “Tongue 01”.

    Then in the daz studio joint editor I can only edit the name and label, not the id. If I change the name to “mytongue01“ and save the scene then in the duf file I get id = “mytongue01“ and name = “mytongue01“. So this is proof that in daz studio the bone id and name are always the same. At least this is what the joint editor does.

  4. Thomas Larsson repo owner

    No, not the local id in the scene file, the id in the file that the url refers to, which is the part of the url after #.

  5. Thomas Larsson repo owner

    I had not quite understood when to use IDs and names, and the code that converts between the two was quite messy. It has been cleaned up in the latest commit. Let us hope that I didn’t ruin anything.

  6. Alessandro Padovani

    If it may help. I tried saving a pose preset and again in the duf file there’s “tongue01“, not “tongueBase“. I suppose we have to use the id in the scene file, while the url may be the reference the item comes from, if this makes any sense. Then the animation file states “name:tongue01“ suggesting it’s using the name, but again the joint editor always makes the name and id the same for bones.

  7. Thomas Larsson repo owner

    Pose presets use the bone names, morph presets use the bone IDs. E.g., the left thigh bones are called (lThighBend, lThighTwist) in a pose preset but (lThigh, lThighTwist) in a morph preset. Don't ask me why.

    Here is an excerpt from Base Pose Kneeling B.duf

                {
                    "url" : "name://@selection/lThighTwist:?rotation/y/value",
                    "keys" : [ [ 0, -10.14235 ] ]
                },
                {
                    "url" : "name://@selection/lThighBend:?rotation/x/value",
                    "keys" : [ [ 0, -92.58007 ] ]
                },
    

    and here is one from pCTRLLegsSpreadLeft.dsf

                "formulas" : [
                    {
                        "output" : "lThigh:/data/DAZ%203D/Genesis%208/Female/Genesis8Female.dsf#lThigh?rotation/z",
                        "operations" : [
                            { "op" : "push", "url" : "Genesis8Female:#CTRLLegsSpreadLeft?value" },
                            { "op" : "push", "val" : 79 },
                            { "op" : "mult" }
                        ]
                    },
                    {
                        "output" : "lThighTwist:/data/DAZ%203D/Genesis%208/Female/Genesis8Female.dsf#lThighTwist?rotation/y",
                        "operations" : [
                            { "op" : "push", "url" : "Genesis8Female:#CTRLLegsSpreadLeft?value" },
                            { "op" : "push", "val" : 60 },
                            { "op" : "mult" }
                        ]
                    }
    

    As I wrote in a recent blog post, the plugin can now save morph presets, so in principle we would need to convert names to ids there. But only pure shapekey morphs can be exported, so there are no bone names, and besides the morphs don't show up in DS.

  8. Log in to comment