Sidor

Wednesday, December 18, 2019

UDIM Support

UDIM support has recently been added to Blender 2.82 Alpha. This is very useful for the Daz Importer, because the UV coordinates in Daz Studio are arranged in UDIM tiles, at least for the Genesis 3 and 8 characters.

Since there are several skin materials, editing them consistently is tedious and error prone. The Mini Material Editor addresses this to some extent, but its power is quite limited. With UDIMs we can combine all skin materials into a single one, which we can then edit using the powerful node editor.
Before an UDIM material can be created, the blend file must be saved and the textures saved locally. The reason for this is that UDIM requires that textures follow a certain naming convention. Hence new textures with the appropriate names must be created, and you probably don't want to litter your Daz installation with these extra textures.
Here is the face material for the Genesis 8 Female character. The diffuse texture node has extension = Repeat and source = Single Image.
Once local copies of the textures have been created, the new Make UDIM Materials button becomes active in the Finishing section. Logically it belongs to the Materials section, but if the character has separate anatomy meshes (geografts), they should be merge with the character before making UDIMs.
A pop-up dialog with a list of all materials appears. The selected ones are going to be replaced by a single material with tiled textures. Which of the materials is specified at the bottom of the dialog. It is the first material with textures in the first tile.
After the script has been executed, all selected material have been removed except for the target material Face-3, and all polygons of the removed materials now use Face-3 instead.

The textures nodes have been changed like this. A "T_" has been added in front of the texture name, extension = Clip, and source = Tiled.

In the UV editor, we can now see the tiles of the tiled texture. Notice that the tile labels equal the old material names.
Now let us turn to the other new button, Set UDIM Tile. It is useful when the character is exported with some geograft, e.g. genitals. Here are the UV coordinates of the New Genitalia for Victoria 8 and the corresponding torso texture.
The problem is that the UVs are located in the first tile, but the torso texture will end up in the second tile; its full name is G8FBaseTorsoMapD_1002.
To move the UV coordinates to a specific tile, we use the Set UDIM Tile button. This must be done before Merge Anatomy, because all UV coordinates are moved to the same tile. Select the geograft and press Set UDIM Tile.
Select the tile we want to move the UVs to, and press OK.
The UVs are now moved to the second tile.
Next we Merge Anatomy and Make UDIM Materials. The genital UV coordinates are now correctly located in the second tile.

Sunday, December 15, 2019

Brighter Eyes

A common problem with Genesis 8 characters is that the eyes tend to be too dark in Blender.
The reason for this is that the eye textures are quite dark.
Somehow Daz Studio manages to avoid this problem, but it is not so easy to emulate this in Blender. Therefore the Daz importer now has an option to brighten the eye textures. This option appears at the bottom of the import menu, and is set to a value which is reasonable for Genesis 8.
If Brighten Eyes is set to something else than 1.0, an extra multiply node is generated for the iris and sclera diffuse channels. It multiplies the eye texture with a more than white color, whose HSV value equals the Brighten Eyes factor.

And now the eyes render much better.
The eyes still look a little strange. It looks like the sclera rests like a disc on top of the eye, and is clearly distinguishable from the rest. But if you look carefully the same effect is visible already in the dark eyes on the top.

Monday, December 2, 2019

Moving to Git


Bitbucket has decided to remove Mercurial support from Bitbucket Cloud and its API. Mercurial features and repositories will be officially removed from Bitbucket and its API on June 1, 2020. This affects the DAZ Importer.

The Mercurial repo, including all history, has been renamed to DAZ Importer Archive, and the DAZ Importer has been changed to a brand new git repo. Actually, I think it can be a good thing to clean out ancient stuff from the repo and make it more lightweight.

The old Mercurial repo is here.

The old issue tracker is here.

The new git repo is here.

The new issue tracker is here.

The current version can be downloaded as a zip file from here. Actually, that should be the same as before.