Introduction

The Foundry’s Blink framework allows you to define your own image processes, and write fully customisable effects for your Nuke pipeline.

The cornerstones of the Blink framework are Blink Kernels. A kernel contains a piece of code that will run once for every pixel in an output image, and describes what computation should be executed to produce the output picture. This code is run in massively parallel processes, which makes it very fast to compute.

The power of the Blink framework is that it allows you to write your code once and run it on any supported device. With Blink, your code can be run on your machine’s GPU, to take advantage of its massively parallel processing capabilities, or on the CPU, for environments like cloud-based farm rendering services, without needing to change any code. Kernels are generated and compiled on-the-fly, which allows you to develop your BlinkScripts directly in Nuke’s editor and see the effects of those changes immediately, as well as switch between GPU and CPU devices at will.

Once a BlinkScript has been written, it can be used like any other node within Nuke, allowing for non-technical artists to manipulate Blink effects without needing to understand the code. BlinkScript nodes can have dynamic user parameters that can be saved, loaded and animated, and nodes can be published and shared, allowing multiple artists to use the same effects.

This user guide will give you the information you will need to start writing your own kernels and leverage the power of Blink for your VFX workflows.

Warnings

A part of what makes BlinkScripts so powerful is that they allow you to rip open the bonnet and directly tinker with the engine of Nuke. While whacking a supercharger onto your V8 engine can lead to an improved racing car, doing so incorrectly can cause a horrendous crash. We make every effort to prevent problems where possible, but we cannot predict all the problems you will encounter when running custom code. However, there are some common issues.

GPU Timeouts

Complicated kernels can cause driver timeouts on the GPU if they take too long to execute. The lower the specifications of your GPU, the more likely this is to happen.

Vectorization

Vectorization will attempt to optimise Blink kernels on the CPU with SIMD instructions, but may result in noticeably longer compile times for very large kernels, and there is no guarantee that your code will be vectorizable.

Crashing and Infinite Loops

Since the BlinkScript node allows arbitrary code to be written and run, it is possible to either crash or lock up Nuke. The BlinkScript node cannot check your code to make sure it is sensible before running it, so we advise you to be careful with what you write!

Requirements

For GPU acceleration:

  • An AMD GPU able to run OpenCL 1.2 and above.

or

  • An NVIDIA GPU with compute capability 3.5 and above, able to run OpenCL 1.2 and above.

  • NVIDIA driver versions capable of running CUDA 11.8, or above. Driver versions 522.06 (Windows) and 520.61.05 (Linux), or above are required.