Lighting in compositing in Blender EP9

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hey blender bob here i always try to show you stuff you will never find anywhere else or bring a different approach to it and this time i'm gonna blow your mind for this entire clip i only rendered a single frame and to render the entire clip it took about 35 seconds on my crappy machine i told you i would blow your mind if you ever learned at school that the primary colors are yellow red and blue well this is totally wrong they are actually magenta cyan and yellow red is actually a mix of yellow and magenta but this is for pigments if you mix color together it's called subtractive synthesis because pigments actually absorb color so you start with a white light and it absorbs color and it absorbs the light energy that's why black surfaces are warmer in the sun than white in 3d is the complete opposite we start with black and we add light that's why it's called the additive synthesis so if you mix a blue light with a red light you will get a magenta result and if you make a christmas scene and you light everything in red and green well don't be surprised if everything turns out yellow but the point of all this for this exercise is that light adds on top of each other okay so let's take the monster there are three lights in the scene one is red one is blue and one is green they could have been any colors it's just for the purpose of this exercise if we look at the lights individually this is what it looks like the red the green and the blue now what i did was to remove all the colors from the light and render each light separately and this is how you set it up it's quite simple actually you just create a collection for every light in your scene then you create render layers and in each render layer you will have one light turned on so layer spotlight one only has spotlight one on and layers but light two only has spotlight two on and it goes on like this now we're going to add the color back into the compositing and it's quite simple you create an rgb node you put it red and then you create a mixed node you put it in multiply and you multiply them together and you get the exact same result you do the same thing for the green light and for the blue light now we've just learned that lights add on top of each other so let's add the red and the green together and then combine this result with the blue and look at this the result is we get the exact same thing as the original image we had to begin with and you lose absolutely zero quality when you do this now the cool thing is i use rgb but i can change the colors of my spot anytime i want in compositing and i get a very very fast result and the cool thing is that it works both ways i could pick some colors in the compositing and instead put them in the lights the real lights and render it and i'm going to get the exact same result as what i got in the comp and this is how i managed to do the sequence we saw at the beginning i had all my rendered layers i created rgb nodes that i multiplied with each layer and then added them all together and i get this result and now i have total control on the lighting i can do whatever i want i can turn some lights on some lights off i can change the color of the lights i can change intensity i could change the gamma of the lights if i want to which is not really possible in real life and then you just need to adjust all the colors the way you want them and play with intensities and you can keyframe all that stuff and that's how you create the sequence i showed you at the beginning this is the same setup in nuke you can see it's much more compact that's because the way nuke works the nodes themselves they only have connections they're just little boxes but all the attributes are on the side when you double click on it you can see all the attributes appearing here instead of having it on the node directly also the great node that i'm using has a lot of attributes black point white point lift gain multiply offset gamma it's all in the same node and if i wanted to redo this in blender i would have a gigantic network and would be unusable and this is the same thing in natron neutron is a copycat of nuke it's open source it's free it's not that stable but it does the exact same work and it's actually faster than nuke for this now the first time i used this technique was on final destination 3 there's this roller coaster scene and one of the scene was completely rendered and took forever to render it was like 20 minutes per frame and the scene took like four days to render i don't know it took forever and the vfx soup asked me to put a orange light and a blue light on the entire roller coaster and i didn't want to render the entire thing and i knew that this guy was picky it was like you know but two percent more science and stuff that you can barely tell so that's what i did i rendered one spot in white intensity of one same thing for the other side and then in comp i multiplied the color and put it in additive on what was already rendered and we saved a lot of time doing this we didn't have to render everything and at the time it's not like today where you you know you change something you see the refresh live on your screen it took 20 minutes per frame so imagine you make a change try something poof now you have 20 you have to wait 20 minutes to see the result well that's three tests per hour so you save a lot of time by doing this in comp now don't you ever ever flicker a light in the cg scene always do it in comp because if the cg supervisor the director the art director whatever they come and they say you know what make the flickering a little bit faster you have to re-render the entire thing if you ever give me a scene where you flicker a light in the 3d scene and if you've been following this channel you know what's going to happen tell me in the comments what's gonna happen if you do this this is a simple real-life example of lighting in comp so this is the setup in blender where the bird on a motion path with three lights in there there was a light from the windows an ambient light and a light that comes from the environment since i didn't have an hdri for the shot what i did is i took the plate and i used it as an hdri so this way i would get the same color balance three passes the fake hdri the second one is an ambient just to fill the shadows and the third one is the light from the windows this is the setup for the comp it's really simple we start with the plate and then we add our three layers on top of each other they all have a great node to change them to adjust them the first one is mix as over instead of addition because otherwise it would be just transparent at the end there's a little blurred node because everything is too sharp when it comes out of cg so always blur your stuff you can see what it does here when i adjust the light in comp here i can add more or less light coming from the window after making all the adjustments i add the blur node because everything that comes from cg is too sharp a little saturation and a light wrap light wrap will just wrap the light around the object and make it feel more integrated when you have very strong light source in the background after this i pre-multiply it and i put it over the background but wait a minute didn't we have the background already in the back we did but look what happens if i disconnect it now i get this fringe around the bird and it looks pretty bad so simple solution you crump it on the plate and then you re-camp it on the same plate i'm not a professional compositor maybe there's a better way to do it but this is how i do it this is not the original comb by the way this is something i just set up for this demo because after this there's a few steps to integrate the bird even more with the collars and matching the blacks and all this stuff i'm not done yet there's another technique we can use to re-light stuff in comp it's a little bit tricky uh it's not something that we use all the time but when we use it it's only to create like little rim lights or little highlights here and there that compositors will do directly in compositing without having to go send the scene back to 3d re-light it and re-render it i'm not going to go in details on how to do this in noob because this is blender bomb not the new bob but i just want to show you that it's possible this is a completely black image it has two layers one is a normal pass and the other one is a point position pass and you can light this image there's nothing on it but you can light it it's really cool and you can also create a point cloud from this image that will give you a 3d representation of where stuff is in 3d space unfortunately that doesn't work very well with blender because blender is z up and all the other software working y up and all the colors and normals everything is inverted you need to swap them and still it doesn't work very well blender institute please give us the possibility to work y up nobody works z up except 3d max everybody else is working why up and it makes much more sense please give us the possibility to switch from one to another it's nice huh you start from a 2d image and you create a 3d geometry inside your compositing package so the barbershop was a little bit extreme i mean there's like 15 lights in there this is not something you do all the time but it's just to show you how powerful the technique is and i would never render all these passes with white lights and give it to a compositor and say well deal with it you do the lighting of course not i'm the 3d guy that's my job i do the lighting so i would do a pre-comp and then i would give it to them and they can tweak and adjust it as needed very soon i will be able to show you a very good example we did on the movie clouds that's going to be released on disney plus the trailer is out but the movie's not out yet as soon as it's out i should be able to show you a lot of cool stuff we did on that movie and that's it for this week i'm also on facebook just search for blender bob so if you have any questions we can chat it's gonna be easier this way than the youtube comments the youtube comments i'm trying to answer everybody but i'm getting lost there's just too many and replies from old clips i did before and replies of replies and replies of replies and so if i don't answer your comment i'm sorry it's just because i'm completely lost okay all right see you next week probably bye this is a vulcan this is a dyslexic vulcan
Info
Channel: Blender Bob
Views: 11,088
Rating: undefined out of 5
Keywords:
Id: WZD-MTXwP4c
Channel Id: undefined
Length: 10min 3sec (603 seconds)
Published: Sun Sep 27 2020
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.