Would you like to inspect the original subtitles? These are the user uploaded subtitles that are being translated:
1
00:00:03,183 --> 00:00:03,933
In this lesson,
2
00:00:03,933 --> 00:00:07,611
we're going to learn how to output our mask into an
3
00:00:07,611 --> 00:00:11,182
image sequence for later use.
4
00:00:11,183 --> 00:00:16,183
OK, so we're right here where we left off in our last lesson.
5
00:00:16,183 --> 00:00:20,182
And I want to use this as an example of how to show you,
6
00:00:20,183 --> 00:00:20,583
basically,
7
00:00:20,583 --> 00:00:25,336
how to get this Roto Node that we've created out our project
8
00:00:25,336 --> 00:00:30,433
as an alpha and then bring it back in to use in the same way
9
00:00:30,433 --> 00:00:32,183
that you would use a Roto Node.
10
00:00:32,183 --> 00:00:35,728
So you're going to know the difference between what's it look like if
11
00:00:35,728 --> 00:00:37,627
I'm using an alpha channel with an image like this,
12
00:00:37,627 --> 00:00:40,183
or what's it look like if I'm using the Roto Node.
13
00:00:40,183 --> 00:00:45,182
And then we can use the Roto Node to achieve creating that alpha.
14
00:00:45,183 --> 00:00:47,182
Now, why would you ever want to do this?
15
00:00:47,183 --> 00:00:51,183
Sometimes, you might start out with an alpha channel in the first place.
16
00:00:51,183 --> 00:00:52,933
And you didn't have a Rotoscope So it would be useful in that
17
00:00:52,933 --> 00:00:55,183
case just to know how to hook these up.
18
00:00:55,183 --> 00:00:58,644
But why would you ever have a Roto Node,
19
00:00:58,644 --> 00:01:02,182
and then output an alpha, and then bring it back in?
20
00:01:02,183 --> 00:01:07,029
Well sometimes, whenever you're working on a project that is like a feature film,
21
00:01:07,029 --> 00:01:12,182
a lot of times, Roto Nodes are really going to slow down your playback over time.
22
00:01:12,183 --> 00:01:15,455
If you have lots of points in your Rotoscope that you've created,
23
00:01:15,455 --> 00:01:19,383
lots of key frames, it's just going to be that much more information,
24
00:01:19,383 --> 00:01:23,183
that much more data that NUKE has to calculate.
25
00:01:23,183 --> 00:01:28,183
So pre-rendering off the Rotoscope is a great way to speed up your workflow.
26
00:01:28,183 --> 00:01:31,728
However, if it's not slowing you down, you probably don't want to pre-render,
27
00:01:31,728 --> 00:01:34,183
because it is possible to lose a little bit of data.
28
00:01:34,183 --> 00:01:38,183
And it's also just a extra step that you have to go through that really isn't
29
00:01:38,183 --> 00:01:42,183
necessary if you're not experiencing any playback issues.
30
00:01:42,183 --> 00:01:45,183
Also, sometimes you might be creating a Rotoscope for somebody else.
31
00:01:45,183 --> 00:01:49,182
And they may prefer to receive it as an alpha channel instead
32
00:01:49,183 --> 00:01:53,182
of just getting the Roto Node and bringing it from your NUKE
33
00:01:53,183 --> 00:01:55,183
script into their NUKE script.
34
00:01:55,183 --> 00:01:57,183
But you definitely want to ask first.
35
00:01:57,183 --> 00:02:01,183
If someone requests a Rotoscope from you, find out what format they prefer.
36
00:02:01,183 --> 00:02:06,546
So now that we know how to create this Roto from our last lesson,
37
00:02:06,546 --> 00:02:10,183
let's find out how to create an alpha from this.
38
00:02:10,183 --> 00:02:13,183
So the first thing we need to do is bring in a Write Node.
39
00:02:13,183 --> 00:02:16,183
So I'm just going to have everything deselected.
40
00:02:16,183 --> 00:02:18,183
And we'll go ahead and grab that Write Node.
41
00:02:18,183 --> 00:02:21,183
So just come up here to your Image button and choose Write.
42
00:02:21,183 --> 00:02:23,849
Now, I didn't have anything selected because sometimes,
43
00:02:23,849 --> 00:02:27,875
if you just drop in a Write Node with Node selected up here,
44
00:02:27,875 --> 00:02:31,183
it can move your pipes around a little bit.
45
00:02:31,183 --> 00:02:32,413
So that's not what I want to do,
46
00:02:32,413 --> 00:02:35,283
because I have a very specific place that I want to plug
47
00:02:35,283 --> 00:02:38,183
this Write Node into my Node Tree.
48
00:02:38,183 --> 00:02:41,183
And that's going to be right here at my Roto Node.
49
00:02:41,183 --> 00:02:45,468
So you may wonder why not plug it in at the last node in our tree,
50
00:02:45,468 --> 00:02:49,183
which is what we're viewing right now, that Merge Node.
51
00:02:49,183 --> 00:02:51,183
And that's because I don't want any of this data yet.
52
00:02:51,183 --> 00:02:57,599
I want just the raw Rotoscope and not really wanting to
53
00:02:57,599 --> 00:02:59,182
deal with the background that we added in.
54
00:02:59,183 --> 00:03:01,183
So let's not even view this.
55
00:03:01,183 --> 00:03:05,183
Let's just view what we have coming through that Write Node.
56
00:03:05,183 --> 00:03:05,683
So basically,
57
00:03:05,683 --> 00:03:09,182
now this looks the same as what it was when we were creating our Rotoscope.
58
00:03:09,183 --> 00:03:11,182
I can double-click on the Roto Node.
59
00:03:11,183 --> 00:03:15,182
And it looks the same as when we were drawing and animating that out.
60
00:03:15,183 --> 00:03:18,182
So I can close this back out.
61
00:03:18,183 --> 00:03:18,683
And now,
62
00:03:18,683 --> 00:03:24,183
basically what we need to do is to tell the Write Node what we want it to make.
63
00:03:24,183 --> 00:03:26,754
So if I just told it to write from this point here,
64
00:03:26,754 --> 00:03:31,183
we would get this whole image, just this RGBA image,
65
00:03:31,183 --> 00:03:33,183
of our actress waving.
66
00:03:33,183 --> 00:03:36,819
And we wouldn't have the alpha because there was no
67
00:03:36,819 --> 00:03:39,183
alpha channel in the original.
68
00:03:39,183 --> 00:03:43,183
And you can tell that by looking at these little thumbnails here at the bottom.
69
00:03:43,183 --> 00:03:46,364
So an alpha channel, or an image that has an alpha channel,
70
00:03:46,364 --> 00:03:49,183
is going to have another box here on the end that will be white.
71
00:03:49,183 --> 00:03:53,183
And you can see what that would look like here in the Merge Node.
72
00:03:53,183 --> 00:03:58,259
So we need to basically tell the Write Node only to
73
00:03:58,259 --> 00:04:01,183
look at one of these channels.
74
00:04:01,183 --> 00:04:04,182
And it's going to be using the Roto as an alpha for that.
75
00:04:04,183 --> 00:04:08,183
So to do that, all we have to do is come up here to our Write Node.
76
00:04:08,183 --> 00:04:09,183
Go to Channels.
77
00:04:09,183 --> 00:04:11,182
And choose Alpha.
78
00:04:11,183 --> 00:04:15,683
And you may wonder now why is it red,
79
00:04:15,683 --> 00:04:20,183
because we expect alphas to look just like a black and white image.
80
00:04:20,183 --> 00:04:25,582
And the reason is because NUKE looks at that information and just
81
00:04:25,582 --> 00:04:29,182
drops it into the first channel that it sees.
82
00:04:29,183 --> 00:04:32,183
And it doesn't see the alpha channel first, which would be white.
83
00:04:32,183 --> 00:04:34,182
It sees the red channel first.
84
00:04:34,183 --> 00:04:37,516
So that's why we're seeing it in red right here,
85
00:04:37,516 --> 00:04:41,183
and also because we're viewing this as RGBA.
86
00:04:41,183 --> 00:04:45,683
If I look at my green channel, which is second after the red channel,
87
00:04:45,683 --> 00:04:47,183
there's nothing here.
88
00:04:47,183 --> 00:04:48,182
It's just a black channel.
89
00:04:48,183 --> 00:04:50,182
And the same goes for blue.
90
00:04:50,183 --> 00:04:53,849
If I look at the alpha channel, we're not going to see anything,
91
00:04:53,849 --> 00:04:56,183
because it's actually not in the alpha channel yet.
92
00:04:56,183 --> 00:05:01,182
It's basically the alpha information being stored in the red channel.
93
00:05:01,183 --> 00:05:03,627
If we look at this red channel, it's going to be white,
94
00:05:03,627 --> 00:05:08,183
because always, your RGBA channels are black and white images.
95
00:05:08,183 --> 00:05:11,183
And then the computer looks at that image.
96
00:05:11,183 --> 00:05:15,516
And it basically looks at it to figure out how to blend the RGBA
97
00:05:15,516 --> 00:05:18,182
channels together to give you a color image.
98
00:05:18,183 --> 00:05:20,029
So whenever we look at RGBA,
99
00:05:20,029 --> 00:05:24,182
we have red because all of our other channels are basically blank.
100
00:05:24,183 --> 00:05:29,183
So now that we have that all figured out, let's go ahead and write this out.
101
00:05:29,183 --> 00:05:33,183
So we need to come over here to our file and click this
102
00:05:33,183 --> 00:05:35,183
little button right here to tell it where we want it to
103
00:05:35,183 --> 00:05:40,183
write this image sequence to.
104
00:05:40,183 --> 00:05:40,433
OK,
105
00:05:40,433 --> 00:05:45,183
so I'm right here inside of your Project files in your Reference files folder.
106
00:05:45,183 --> 00:05:47,933
And I want to create a new folder for this sequence
107
00:05:47,933 --> 00:05:49,182
that we're going to write out.
108
00:05:49,183 --> 00:05:52,183
And so you can do this right here.
109
00:05:52,183 --> 00:05:54,183
You don't have to grab a different window.
110
00:05:54,183 --> 00:05:56,968
You can do it right up here in the corner by just going
111
00:05:56,968 --> 00:05:59,182
to this button to create a new folder.
112
00:05:59,183 --> 00:06:00,183
And then it's going to ask you what you want to name it.
113
00:06:00,183 --> 00:06:03,183
And we'll just call this waving_alpha.
114
00:06:03,183 --> 00:06:09,183
And let's put a underscore in there just where that space would be.
115
00:06:09,183 --> 00:06:11,182
Go ahead and say OK.
116
00:06:11,183 --> 00:06:14,183
And then it's automatically going to take you inside of that folder.
117
00:06:14,183 --> 00:06:15,183
So that's why all those disappeared.
118
00:06:15,183 --> 00:06:19,183
And we can see that in our path here.
119
00:06:19,183 --> 00:06:24,182
And so now, we just need to tell it what we want this to be called as a sequence.
120
00:06:24,183 --> 00:06:24,849
So basically,
121
00:06:24,849 --> 00:06:30,182
every single one of our frames is going to get written out as a different image.
122
00:06:30,183 --> 00:06:33,183
And we have 89 images here.
123
00:06:33,183 --> 00:06:38,183
So that is going to definitely need to be in a folder.
124
00:06:38,183 --> 00:06:40,001
We wouldn't have just wanted to dump those all into
125
00:06:40,001 --> 00:06:42,182
the root of that reference file.
126
00:06:42,183 --> 00:06:47,183
So let's just call this, again, waving_alpha, because that's what this is.
127
00:06:47,183 --> 00:06:50,183
And I'll put a underscore in there just to separate those two words.
128
00:06:50,183 --> 00:06:53,182
Just a little more clean for your file path.
129
00:06:53,183 --> 00:06:55,754
Sometimes, you might have a different naming convention depending on,
130
00:06:55,754 --> 00:06:58,182
maybe, where you work, or where you go to school.
131
00:06:58,183 --> 00:07:02,182
It's up to you how you're going to name that.
132
00:07:02,183 --> 00:07:05,182
And then, we need to tell it that this is going to be a sequence.
133
00:07:05,183 --> 00:07:07,183
We're going to have multiple files written out here.
134
00:07:07,183 --> 00:07:12,183
And NUKE needs to be able to recognize that each file is in a sequence.
135
00:07:12,183 --> 00:07:17,183
And it's going to name those according to where it falls in this sequence.
136
00:07:17,183 --> 00:07:20,183
So if it's frame five, we'll have a five here.
137
00:07:20,183 --> 00:07:22,933
Now, before I just have a number butted right up against this word,
138
00:07:22,933 --> 00:07:25,183
I like to put another underscore.
139
00:07:25,183 --> 00:07:25,683
And then,
140
00:07:25,683 --> 00:07:29,182
we use a special character to tell it that we want it to
141
00:07:29,182 --> 00:07:32,182
fill in this number as it renders for us.
142
00:07:32,183 --> 00:07:35,183
And I really just like to use the number key.
143
00:07:35,183 --> 00:07:39,182
So I'll just hold Shift and hit the 3 on the top on my keyboard.
144
00:07:39,183 --> 00:07:41,001
And that'll put in one of those little pound signs,
145
00:07:41,001 --> 00:07:45,182
or number keys, hash tag, whatever you want to call it.
146
00:07:45,183 --> 00:07:48,183
And then, you need to think about how many of these you want.
147
00:07:48,183 --> 00:07:52,182
So this is only going to allow for it to fill in up to one digit.
148
00:07:52,183 --> 00:07:54,182
But we have 89 frames.
149
00:07:54,183 --> 00:07:56,182
So that's getting into the double digits.
150
00:07:56,183 --> 00:07:58,182
So you'll want at least two.
151
00:07:58,183 --> 00:08:00,183
But I always like to have a leading zero.
152
00:08:00,183 --> 00:08:04,182
So my last frame would be 089.
153
00:08:04,183 --> 00:08:07,182
So I like to put in two more so I have a total of three.
154
00:08:07,183 --> 00:08:09,910
So anytime I have two digits,
155
00:08:09,910 --> 00:08:14,182
I'll put in three special characters that it will fill in.
156
00:08:14,183 --> 00:08:18,183
Now we need to decide what kind of file extension we want.
157
00:08:18,183 --> 00:08:20,182
So there's lots of different choices.
158
00:08:20,183 --> 00:08:24,182
I personally prefer a png sequence for something like this.
159
00:08:24,183 --> 00:08:27,182
You could do an EXR if you wanted a totally lossless format.
160
00:08:27,183 --> 00:08:29,001
But for something like this,
161
00:08:29,001 --> 00:08:32,683
the only thing that I would avoid would be a JPEG sequence
162
00:08:32,683 --> 00:08:35,183
simply because those are not lossless.
163
00:08:35,183 --> 00:08:36,183
They are very lossy.
164
00:08:36,183 --> 00:08:39,183
And you might end up with a little aliasing around those edges.
165
00:08:39,183 --> 00:08:41,182
So we'll just do a png sequence for now.
166
00:08:41,183 --> 00:08:45,183
And so you just want to put a period and then type in png.
167
00:08:45,183 --> 00:08:47,183
And then we're ready to render.
168
00:08:47,183 --> 00:08:49,183
So go ahead and hit Save.
169
00:08:49,183 --> 00:08:53,183
And you can come down here to Render and hit that button.
170
00:08:53,183 --> 00:08:57,183
And this is also a little interesting how this does this.
171
00:08:57,183 --> 00:09:03,183
So whenever the sequence was originally imported, it was named 0-89.
172
00:09:03,183 --> 00:09:05,183
But NUKE likes to start at 1.
173
00:09:05,183 --> 00:09:08,182
So you can write it out from 1 to 90.
174
00:09:08,183 --> 00:09:10,183
It's still the same amount of frames.
175
00:09:10,183 --> 00:09:12,183
It's just not starting at zero.
176
00:09:12,183 --> 00:09:16,183
Or you could change this to a zero and write to 89.
177
00:09:16,183 --> 00:09:18,183
Either way, you're going to get pretty much the same result.
178
00:09:18,183 --> 00:09:20,183
So I'm just going to leave this as it is.
179
00:09:20,183 --> 00:09:21,183
Go ahead and hit OK.
180
00:09:21,183 --> 00:09:25,183
And you can see that renders really, really quickly.
181
00:09:25,183 --> 00:09:32,183
So now, I want to bring back in that sequence that we just created.
182
00:09:32,183 --> 00:09:35,182
OK, so I've just got it here in your Reference files.
183
00:09:35,183 --> 00:09:36,183
So let's go ahead.
184
00:09:36,183 --> 00:09:38,183
And that's going to be the waving_alpha.
185
00:09:38,183 --> 00:09:42,183
So we'll just grab that folder and drop it onto our Node Tree.
186
00:09:42,183 --> 00:09:46,183
And you can see it moved those around just based on what I had selected.
187
00:09:46,183 --> 00:09:47,183
I'm going to put that back into place.
188
00:09:47,183 --> 00:09:50,183
And we'll just have this over here to the side for a second.
189
00:09:50,183 --> 00:09:56,183
And usually, you don't want to disconnect anything from your tree.
190
00:09:56,183 --> 00:10:00,183
So basically, what I want to do is just disconnect as little as possible.
191
00:10:00,183 --> 00:10:05,183
So I know that I'm going to be using the A pipe with this later on.
192
00:10:05,183 --> 00:10:07,182
So I'm going to disconnect that one for now.
193
00:10:07,183 --> 00:10:12,182
And then we can put the Write Node over here to the right.
194
00:10:12,183 --> 00:10:16,183
And then we'll put the Roto directly out to the side of the Read Node.
195
00:10:16,183 --> 00:10:21,183
Then, I'm going to put this Read Node right underneath that Write Node.
196
00:10:21,183 --> 00:10:23,111
So this is a good way to be able,
197
00:10:23,111 --> 00:10:27,259
if you're going to leave the Roto and the Write here on your Node graph,
198
00:10:27,259 --> 00:10:31,092
to just be able to see visually this Roto and this
199
00:10:31,092 --> 00:10:38,182
Write Node output this new Read Node, which is our alpha that we've created.
200
00:10:38,183 --> 00:10:43,721
So now what I want to do is copy this alpha channel
201
00:10:43,721 --> 00:10:47,183
into the alpha for this Read Node.
202
00:10:47,183 --> 00:10:47,364
Now,
203
00:10:47,364 --> 00:10:50,183
that might be a little bit confusing if you haven't gotten into channels yet.
204
00:10:50,183 --> 00:10:52,183
So I'll explain it to you.
205
00:10:52,183 --> 00:10:52,883
Basically,
206
00:10:52,883 --> 00:11:00,849
we want to have another little white bar here at the end by the
207
00:11:00,849 --> 00:11:04,183
time we have united these two images together.
208
00:11:04,183 --> 00:11:06,721
So right now, even though this is only a red channel,
209
00:11:06,721 --> 00:11:11,182
it has the look of an alpha, because it's just this silhouette.
210
00:11:11,183 --> 00:11:16,683
So we can use a Copy Node to take this red data and tell it to
211
00:11:16,683 --> 00:11:20,183
become the alpha channel for this image.
212
00:11:20,183 --> 00:11:22,183
So let's go ahead and add in a Copy Node.
213
00:11:22,183 --> 00:11:25,516
I'm just going to go ahead and deselect because I don't want it
214
00:11:25,516 --> 00:11:28,183
to automatically hook up any pipes for me.
215
00:11:28,183 --> 00:11:31,183
And the Copy Node is located right up here in your channel.
216
00:11:31,183 --> 00:11:32,182
So just click and hold that.
217
00:11:32,183 --> 00:11:34,183
And come down here to Copy.
218
00:11:34,183 --> 00:11:36,183
And we'll just drop that right in there.
219
00:11:36,183 --> 00:11:38,910
I'm going to put this directly across from the Merge,
220
00:11:38,910 --> 00:11:42,183
because that's what it's going to hook up to a little bit later on.
221
00:11:42,183 --> 00:11:47,183
And then, let's go ahead and tell our viewer to look at the Copy Node.
222
00:11:47,183 --> 00:11:51,183
Now, right now, we get an error because we haven't changed anything yet.
223
00:11:51,183 --> 00:11:55,766
But let's talk about how we know which one of these
224
00:11:55,766 --> 00:11:58,183
pipes needs to be hooked up where.
225
00:11:58,183 --> 00:12:07,183
So basically, we're wanting to look at our original image as a the background,
226
00:12:07,183 --> 00:12:08,183
I would say.
227
00:12:08,183 --> 00:12:14,182
So it's similar to the way you're setting up whenever you're doing a Read Node.
228
00:12:14,183 --> 00:12:24,183
So I'm wanting to copy the channel from my alpha into this Read Node here.
229
00:12:24,183 --> 00:12:26,183
So this needs to be my background.
230
00:12:26,183 --> 00:12:29,183
So I'll grab the B pipe and drop that onto the Read Node.
231
00:12:29,183 --> 00:12:34,183
And then we'll take this A pipe and drop it onto the alpha we created.
232
00:12:34,183 --> 00:12:35,182
Now, we still have that error.
233
00:12:35,183 --> 00:12:40,182
And that's because we haven't changed anything inside of the Copy Node.
234
00:12:40,183 --> 00:12:45,001
So right now, it's still trying to copy that default setting of alpha to alpha,
235
00:12:45,001 --> 00:12:49,183
which we don't have an alpha in this file here.
236
00:12:49,183 --> 00:12:51,183
So doesn't really make any sense.
237
00:12:51,183 --> 00:12:57,183
So I'm going to tell it to copy the red and tell that to go into the alpha here.
238
00:12:57,183 --> 00:13:04,183
So to change that, we'll just go to this first option and choose RGBA Red.
239
00:13:04,183 --> 00:13:07,183
So now, as we're viewing this, a little bit of a change happened.
240
00:13:07,183 --> 00:13:08,182
And you can see it now.
241
00:13:08,183 --> 00:13:12,183
As these two images come together, this red has become the alpha.
242
00:13:12,183 --> 00:13:16,182
And then we still have the RGBA information from our
243
00:13:16,183 --> 00:13:19,183
original background Read Node.
244
00:13:19,183 --> 00:13:20,183
And it's been copied here.
245
00:13:20,183 --> 00:13:27,183
So this is a easy way to view this, how it says red goes into alpha.
246
00:13:27,183 --> 00:13:30,183
And it just shows you that right there on the Copy Node.
247
00:13:30,183 --> 00:13:34,182
And then you can also see what's happening based on these little thumbs.
248
00:13:34,183 --> 00:13:36,183
I really like those little thumbs.
249
00:13:36,183 --> 00:13:39,182
It's a really visual way to be able to understand what's happening.
250
00:13:39,183 --> 00:13:39,583
And now,
251
00:13:39,583 --> 00:13:42,183
all we have to do is grab our A pipe from our Merge
252
00:13:42,183 --> 00:13:44,183
Node and drop it onto the Copy Node.
253
00:13:44,183 --> 00:13:48,183
And really, right now, it looks exactly the same.
254
00:13:48,183 --> 00:13:50,182
And that's because we're still viewing the Copy Node.
255
00:13:50,183 --> 00:13:53,183
So let's just take the Viewer and drop it onto the Merge.
256
00:13:53,183 --> 00:13:55,183
And I'll go ahead and hit Play.
257
00:13:55,183 --> 00:13:59,683
And you can see that it's very similar outcome to what we had with a Roto,
258
00:13:59,683 --> 00:14:01,183
pretty much indistinguishable.
259
00:14:01,183 --> 00:14:04,183
If I zoom in here, we're not really getting any aliasing along the edges.
260
00:14:04,183 --> 00:14:08,728
So that was definitely a high enough quality file type
261
00:14:08,728 --> 00:14:11,183
just using that png in this scenario.
262
00:14:11,183 --> 00:14:14,183
So hopefully, you understand a little bit more about channels now.
263
00:14:14,183 --> 00:14:18,182
And you also know how to write out your own alpha channel and
264
00:14:18,183 --> 00:14:20,182
then how to use it in your own project.
265
00:14:20,183 --> 00:14:23,183
So thanks for sticking around and watching this Rotoscoping course.
266
00:14:23,183 --> 00:14:28,183
And good luck in creating some of these techniques in your own projects.
23906
Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.