People getting started with Nuke, even experienced Compositors coming from other software, often seem confused about the Shuffle Node.

Prerequisite knowledge

The first thing to understand, is that in Nuke you’re not limited by 1 RGBA layer.
You will sometime see the word Channel and Layer used interchangeably (example: Multichannel EXR), I prefer to use Channel for single channels: R, G, B and A for example, each of it contained in a Layer: RGBA in this case.

So you can have many Layers.
Each layer contains Channels. Usually each layer would contain 3 or 4 channels (RGB or RGBA), but it could contain up to 8 channels.
Each Channel contains pixels data, which you can thing of as a black and white image.

For the purpose of displaying an image, Nuke displays the first Channel as Red, the second as Green, and the third as Blue. However, the data itself is independent to the Channel, which is merely a container, or a label.

The data can be copied or moved to a different channel, the easiest way to do so is to use a shuffle.

Using the Shuffle node

shuffle

This is what the interface of the Shuffle node looks like. It’s a lot of boxes, and can be a bit confusing at first.
Let’s simplify it for the purpose of learning:

shuffle_simple

That’s better already.
On the top, you have the in knob, where you can pick a layer to shuffle from, along with it’s first 4 channels listed horizontally. Here r, g, b, a.
There is also a 0, which corresponds to full black, or no data; and 1, which corresponds to white, or fill the whole channel with a value of 1.

On the right side, you have the output, with it’s out knob, where you can pick where the data will go.

shuffle_flow

In the above example, each shuffle is going back into it’s own channel.
Let’s look at the a channel and follow the arrow: as we go down, we find a checked box. Once we find a checked box, the data flows to the right side, in this case back to the alpha channel.
We’ve put the data from alpha into alpha, which I like to write as a->a.

As this is a default shuffle, it also does: r->r, g->g and b->b. Let’s mix things out.

shuffle_complex

So, I’m back to a full view of the node, but the concept is still the same, we just follow the arrow.

Let’s look at the green here: We’re putting the data from g into the red channel. What used to be displayed as green will now be displayed as red.
We’re also putting the data of g into a different layer called depth, into a channel called Z.
This basically means that the data from the green channel has been duplicated, and copied into both channels.
We could put green into every single channel if we wanted to, which would result as an image being displayed as monochrome, equivalent to the original data of green.
Here, if we look at every channel, we have:
g -> r
r -> g
a -> b
0 -> a
g -> Z

While you can check as many boxes as you’d like per column, you can only have one checked per line: While you can copy data to multiple channels, each channel can only contain 1 set of data.

Let’s play a game

You can practice using the interface by playing a little game I made.

  • It works the same way as the Shuffle interface, but the data is represented by a liquid.
  • The liquid comes from pipes and has to be put in the right truck.
  • Follow the “orders” on the board on the right.
  • Click the valves to send the liquid in the right truck, then click “Check” or press Enter.
  • You have 60s per game. Faster order deliveries get more points.
  • I haven’t included touch screen support yet, so for now you cannot play on mobile.

If for some reason (small screen for example) the game doesn’t display properly, you can open it in it’s own tab by CLICKING HERE