Sidor

Thursday, July 19, 2018

scimeter.org

Bee reports about a new tool for arXiv users that she helped to create: Scimeter. Having been stuck for a decade and not really on speaking terms with the arXiv moderators, I haven't thought much about physics for the last decade, but here is the cloud that it produces for my arXiv papers:

 
 Couldn't have made it better myself.

Monday, July 16, 2018

Shells and Layered Images

In Daz Studio, a shell is a mesh with zero vertices that is used to add features to the materials of the base mesh. It can be used e.g. for makeup, tattoos and wounds. Shells are also used by Genesis 8 genitals to add color and effects without having to modify the torso material.

Importing the shells directly into Blender makes no sense, because they are empty meshes that don't show up in renders. Instead the Daz Importer uses the information in the shell materials to modify the materials of the base mesh. Here is an example where two bruises have been added to the face and one bruise has been added to the lips:
 The principled face material looks like this:
 The bruise textures are added to the face material inside the node group:
 This node group contains some redundant nodes, which hopefully will go away soon.

 A different way to add layers is to use the Layered Image Editor (LIE) in Daz Studio. Here we have added three small textures to the face texture.
After importing to Blender, the face looks like this. There was also added an extra texture to the lips material.
And here is the node group that computes the diffuse texture. The textures are placed using mapping nodes.
 

Monday, July 2, 2018

Stripped runtime system

In version 1.3 of the Daz importer the face bones drivers use Custom Driver Functions. This represents a major improvement compared to the methods used in earlier versions, because
  1. There no limit to the number of driving properties.
  2. Driver functions can be combined with other drivers.
  3. Performance is much better than with handlers.
However, there is a caveat. The add-on must always be enabled, because the drivers use the function evalMorph, which is defined by the add-on. This is not really a problem as long as you stay on the same computer, but if you send your blend file to another machine which does not have the Daz importer installed, the missing driver function will destroy the face pose completely. A typical situation where this problem may arise is if you send the blend files away to a render farm.


If you look in the DOS/terminal window, you find a lot of error messages of the form

Error in Driver: The following Python expression failed:
        'evalMorphs(self, 2, "Rot")'

Traceback (most recent call last):
  File "<bpy driver>", line 1, in <module>
NameError: name 'evalMorphs' is not defined


Thus clearly the problem is that the drivers for the face bones call the function evalMorphs, which is missing because it defined by the non-available import-daz add-on.

To solve this problem, the definition of evalMorphs and some necessary supporting code has been duplicated in the file runtime_stripped.py, located in the folder with the same name under the import_daz directory. Since this addition is very recent, you need to download the latest development version of the add-on.

To use this file when the import-daz add-on is disabled, follow these steps:

In the Scripting context, select Open to open a text file.

Navigate to the file import-daz/runtime_stripped/runtime_stripped.py.

First enable the Register checkbox, and then press the Run Script button. Finally save the blend file.

Open the blend file again. Since it is the last file saved, it should be found at the top of the Open Recent... menu item.

And now the ugly face is replaced by a smile.

At least this works in this example. It is not clear to me if it will still work if you do batch rendering from a terminal, or if you have do some extra steps as well.