Skip to content

minoue/UDIMTextureImporter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

UDIM Texture Importer for ZBrush

Import UDIM Vector/Normal displacement.
This plugin may still have bugs. Be sure to sve your tool first.

img

Comparison between the original high res sculpt and the one re-sculpted base mesh using exported vector displacement maps. If mesh, UVs, texture maps are all correct and consistent, then the result should be almost the same as the original sculpt. img_compare

There may be a few small artefacts depending on the texture border edges. img_compare

Getting Started

Prerequisties

In addition to being a UDIM naming convention (eg. filename.1001.tif), textures must meet the following requrements.

For MacOS, you must install libtiff first. brew install libtiff

Vector Displacement

  • Tangent Vector
  • 32bit tiff/exr or 16bit float-point exr
  • Mid point 0.0
  • Flip and switch: 25 (ZBrush)
  • Tangent Flip and switch: 25 (ZBrush)
  • Absolute tangent (Mudbox)

Normal Displacement

  • 32bit or 16bit float-point EXR
  • 8/16/32 bit tiff
  • Mid point can be changed between 0-1

Color

  • 8bit tiff/jpg/png or 16bit tiff
  • Supported but extra steps are required
    • Tool loses UVs after importing color textures, so you need to restore it manually. Check the usage section.

Supported tiff compression

  • Deflate
  • None
  • LZW

Installation

Windows10 & ZBrush2022

  1. Go to release page, download the latest and extract it.
  2. Move tiff.dll, zlib.dll, and libdeflate.dll to the same directory as ZBrush.exe. (eg. C:\Program Files\Pixologic\ZBrush 2022\tiff.dll)
  3. Move UDIMTextureImporter_2022.zsc to ZPlugs64 folder.
  4. Move UDIMTextureImporterData to ZPlugs64 folder.
ZStartup/
├─ ZPlugs64/
│  ├─ UDIMTextureImporterData/
│  │  ├─ ZFileUtils/
│  │  │  ├─ ZFileUtils.dll
│  │  ├─ UDIMTextureImporter.dll
│  ├─ UDIMTextureImporter_2022.zsc

MacOS & ZBrush2022

--

Usage

Go to ZPlugin -> UDIM Texture Importer, and select the texture type you want to import.

“”

Displacement

Color

Tool loses UVs after importing color textures because of technical limitation, so you need to restore it manually.

  1. Switch to the lowest subdiv.
  2. Export obj as UV backup.
  3. Switch to the highest subdiv.
  4. Import color textures.
  5. Switch to the lowest subdiv.
  6. Import the obj file to restore UVs.

Build Instruction

Requirements

For MacOS, you can use homebrew: brew install libtiff

For Windows, you may use a package manager such as Chocolatey or build from source code.

How to build

git clone https://github.com/minoue/UDIMTextureImporter
cd UDIMTextureImporter
git submodule update --init --recursive
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Release ../
cmake --build . --config Release --target install

License

GPLv3

Contact

michitaka.inoue at icloud.com

Credits

This software uses the following libraries.

tinyexr / The 3-Clause BSD License / Shoyo Fujita
libtiff / LibTIFF license / Copyright © 1988-1997 Sam Leffler / Copyright © 1991-1997 Silicon Graphics, Inc.
zlib / zlib License / © Jean-loup Gailly, Mark Adler
libdeflate / MIT License / ©ebiggers
FromZ / GPLv3 / © Kazutaka Nakashima
Eigen / MPL2
stb_image / MIT License / © 2017 Sean Barrett