Deep Sample Optimisation for Nuke 16
Created by Marten Blumen
DeepThinner reduces deep sample counts per pixel through seven independent, artist-controllable passes. It dramatically improves downstream compositing speed, memory usage, and deep EXR write times with minimal to zero visual impact.
-
Download the correct plugin for your platform:
- Windows:
DeepThinner.dll
- Windows:
-
Copy the plugin file to one of the following locations:
- Your personal Nuke directory:
~/.nuke/(Linux/macOS) or%USERPROFILE%\.nuke\(Windows) - A shared plugin directory on your
NUKE_PATH - Your studio's custom plugin directory
- Your personal Nuke directory:
-
Copy
menu.pyto the same location as the plugin (or merge its contents into your existingmenu.py). -
Restart Nuke. DeepThinner will appear under Deep > DeepThinner in the node toolbar.
- Nuke 16 with NDK headers installed
- CMake 3.15 or later
- C++17 compiler:
- Windows: Visual Studio 2022 (MSVC 19.x)
- Linux: GCC 9+ or Clang 10+
- macOS: Xcode 12+ / Apple Clang 12+
cd C:\path\to\DeepThinner
mkdir build && cd build
cmake -DNUKE_INSTALL_PATH="C:\Program Files\Nuke16.0v8" ..
cmake --build . --config Release
copy Release\DeepThinner.dll %USERPROFILE%\.nuke\cd /path/to/DeepThinner
mkdir build && cd build
cmake -DNUKE_INSTALL_PATH="/usr/local/Nuke16.0v8" ..
make -j$(nproc)
cp DeepThinner.so ~/.nuke/cd /path/to/DeepThinner
mkdir build && cd build
cmake -DNUKE_INSTALL_PATH="/Applications/Nuke16.0v8/Nuke16.0v8.app/Contents/MacOS" ..
make -j$(sysctl -n hw.ncpu)
cp DeepThinner.dylib ~/.nuke/DeepThinner/
├── DeepThinner.cpp — Plugin source code
├── CMakeLists.txt — CMake build configuration
├── menu.py — Nuke menu registration
└── README.md — This file
- Create a DeepThinner node from Deep > DeepThinner (or press Tab and type "DeepThinner").
- Connect it to your deep stream.
- The default settings (Occlusion Cutoff + Contribution Cull + Smart Merge) are a good starting point.
- Render, then open the Statistics group in the properties to see your reduction results.
- Click Update Statistics to refresh the numbers at any time.
| # | Pass | Default | What It Does |
|---|---|---|---|
| 1 | Depth Range | Off | Clips samples outside a near/far Z range |
| 2 | Alpha Cull | On | Removes samples with alpha at or below a threshold |
| 3 | Occlusion Cutoff | On | Drops everything behind the point where coverage reaches a cutoff |
| 4 | Contribution Cull | On | Removes samples whose visible contribution is negligible |
| 5 | Volumetric Collapse | Off | Collapses runs of low-alpha volume samples into fewer samples |
| 6 | Smart Merge | On | Merges Z-close and colour-similar consecutive samples |
| 7 | Max Samples | Off | Hard per-pixel sample cap; drops deepest first |
- Occlusion Cutoff: 0.9999
- Contribution Cull: 0.0005
- Smart Merge Z tolerance: 0.005, color tolerance: 0.005
- Occlusion Cutoff: 0.999
- Contribution Cull: 0.001
- Smart Merge Z tolerance: 0.01, color tolerance: 0.01
- Occlusion Cutoff: 0.99
- Contribution Cull: 0.01
- Volumetric Collapse: On, group size 8
- Smart Merge Z tolerance: 0.05, color tolerance: 0.05
- Max Samples: 64
| Problem | Solution |
|---|---|
| No reduction showing | Ensure at least one pass is enabled. Check that input has deep data. |
| Banding in volumes | Reduce Volumetric Collapse group size or raise volume alpha max. |
| Edge fringing on transparent obj | Lower Smart Merge color tolerance or disable merge for that section. |
| Statistics say "No samples" | Make sure you've rendered (not just validated). Click Update Statistics. |
| Build error: NOMINMAX | Ensure you're using the provided CMakeLists.txt with Windows defines. |
| Build error: DeepOnlyOp.h | Use DeepThinner v2.0 source — v1 targeted an older Nuke API. |
| Plugin doesn't appear in menu | Check that menu.py is in your ~/.nuke/ or NUKE_PATH directory. |
- Nuke 16.0v1+ (built against the Nuke 16 NDK)
- Tested on Windows 11,
- Passes through all channels unchanged — safe for any deep pipeline
- Seven independent thinning passes (added Depth Range, Occlusion Cutoff, Contribution Cull, Volumetric Collapse)
- Colour-aware smart merge
- In-panel statistics with Update button
- Artist Guide and Technical Notes in the UI
- Thread-local scratch buffers for zero-allocation processing
- Nuke 16 API (DeepFilterOp)
- Initial release with Z-tolerance merge, alpha cull, and max samples
This plugin is provided as-is for use in production and personal projects. Created by Marten Blumen.