custom groups bug

Issue #11 resolved
Alessandro Padovani created an issue

Tested with daz studio 4.12.0.86, blender 2.81a, plugin commit 48e20a5

It seems that for custom groups the plugin actually creates one custom group for every material in the daz figure. This is not necessary since a custom group can be shared among materials. Also this clutters up the add group menu. Below an example with the Fresnel custom group.

Comments (4)

  1. Alessandro Padovani reporter

    Also I may suggest to add a “daz-” prefix to the custom groups created by the plugin. As a possible help to avoid name conflicts when appending data from other blender files.

  2. Thomas Larsson repo owner

    Should work now. There are two cases were custom groups are still duplicated:

    1. Inside other custom groups. I’m worried that linking node trees recursively may lead to problems when rendering.
    2. Groups that are created instead of geometry shells. In DAZ, a shell is an empty mesh whose purpose is to modify the material. Since empty meshes don’t show up in Blender, shells are instead translated into custom node groups in the material. Since different shells give different node groups, a new node groups is created for each shell, even if it could be possible that some of them could share data.

  3. Alessandro Padovani reporter

    I’m not sure I understand 1 and 2.

    As for 1 a custom group definition as available in the group menu is just a definition, then it gets instanced in the materials where it is needed, including sub-groups. That doesn’t mean that we need multiple definitions of the same custom group. So I can’t get where the recursion would come into play. Or may be I just misunderstand what you mean.

    As for 2 it is not entirely true that a geometry shell is an empty mesh, though it could be a close approximation in concept. In daz studio a geometry shell is an actual instance of an object, that is created with a push modifier, so it has an offset over the parent geometry. Indeed if you create a shell in daz studio then push it away enough you can see the two geometries in wireframe, also if you change the shell opacity you can see the underneath object. Then personally I do like the shell translated with an empty mesh in blender since I believe this is a more elegant implementation, but I also believe it is important to be aware of the difference with the daz studio implementation.

    As for the custom group issue commit fb8e9cd seems to work fine enough though, so I’d mark this as resolved for now, unless you want to go further. And thank you Thomas as always for the fast fix.

  4. Log in to comment