How to Use Depth Maps in Photoshop Tutorial #Nucly

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
Hello, my name is Rikard. And in this tutorial, I'm going to show you how to use a depth map in Photoshop. In the last couple of years, Adobe has added neural filters to Photoshop, and one of those is the blurred depth that allows you to add shallow depth of field to an image that's all in focus. But hidden inside that neural filter is the ability to output a depth map. And with a depth map, you can create some magic in Photoshop. I'm going to show you how to do that now if you want to follow along. I have included the images in a link in the description of this video. Go ahead, download those and then let's dive into Photoshop. All right, let's go to file open and I'm going to open this 01 file in the assets. Let's go ahead and click open. And first thing we're going to do is go to filter and then down to neural filters. Now these are the AI-assisted filters that are being added to Photoshop. Some are featured, some are still in beta, the one we're going to be using today is depth blur. So let's go ahead and turn that on. Now, if you don't have it downloaded, just click on the little download icon and then the download icon will change to this little radio switch. And we're going to go ahead and turn that on. Now, the depth blur allows you to add basically a depth blur, like a shallow depth of field in your image without having any depth information. So with the lens blur filter in Photoshop, you can do the same thing if you have a depth map. Now when you're doing photography, you're usually not going to have a depth map unless you're using a camera that has depth information. So like the iPhone, for example, does have depth information in their files. And there's also other brands of camera that capture depth information. But in this case, what Photoshop is doing, it is using artificial intelligence to determine what the depth of your image is. So in this case, you can see here our foreground here is in focus and everything else gets more and more out of focus as it goes further away from the camera. Now, here I can add a focal point. So let's say I want to have this car in focus. I can click here and it'll make that in focus. And you can see now our foreground is out of focus and our background is still out of focus. I'm going to go ahead and remove this focal point and just scroll down here and show you a few of these other options. So focal distance, if you're using the focal points by clicking here, then this focal distance is going to gray out because this is essentially doing the same thing, but just doing it manually. So as I move further to the right, my focal distance is going further and further toward this back of the image. So there you can see off in the distance is in focus and my foreground is out of focus. If I move it to the left here, my foreground is going to be in focus and my background is going to be out of focus. All right. Next, this focus range, this is similar to your f stop. If you're a photographer, the lower your F stop is, the shallower the area that's in focus is going to be. And the higher your f stop is, the more of your image is going to be in focus. So for example, if I take this all the way to 100, you can see I have all this in focus and it just goes out of focus toward the back there. Whereas if I put this on zero, almost everything is out of focus except for this very foreground area here. Now, for purposes of demonstration here, I'm going to add a focal point to the car. Okay. And then let's continue scrolling down here. So this is the blur strength. If I turn this up, you're going to have more blurriness in the blurry areas. Haze allows you to add some haze to your image. Honestly, it doesn't do a great job. It looks more like haze on your lens rather than a haze in the air. So let's go ahead and turn that off. And then these allow you to make color brightness, saturation adjustments to your image. Again, not something I would do inside a depth blur filter. I would much rather just do that in Photoshop. And then finally you have grain. Now what we're actually going to be using is none of these things. All we're going to use is this little checkbox here. If I turn that on, you're going to see the depth map that Photoshop's artificial intelligence engine created for this image. So it looked at the image and determined that based on the image information, this is the depth, right? So the foreground or meaning what's closest to the camera is going to be black. And what's further from the camera is going to be white. So here you can see the two cars. You can see the light, the signal light here and here. So it's actually done a really good job of determining the depth. Now, all these settings you can see are grayed out because with this, this depth map is not influenced by any of these things. Okay. So that's all I want. I want to make sure the output is on new layer and I'm going to hit okay, now with this that depth map, we can do two things in Photoshop. We can add depth blur and we can also add depth atmosphere or atmospheric depth. So the first one I want to show you is how to use lens blur with a depth map. So first thing is I need to convert this into a channel now because this is black and white. If I go to my channels, you'll see that my red, green and blue channels all have the same information. So what I can do is I can take the Blue Channel or any one of these red, green or blue and drag this down to the new channel icon down here. A similar to making a copy of a layer. By dragging it to the new layer icon, you can drag a channel to the new channel icon and make a copy of it. And here I'm going to change the name of this by double clicking on it and typing in depth. Now the name of it is not significant, but while you're working in Photoshop, the more you name things, the easier it'll be to remember where things are or to find things later. All right. So let's go back to RGB and then back to our layers palette and I'm going to go ahead and turn this off for now and then take my background, make a copy of it, and we'll call this depth of field. Next, we're going to go up to Filter Blur and we're going to use the Lens Blur. And right away you can see that it's doing something very similar to the depth blur neural filter. So it's using the depth channel which it was added here. So you can see that here, the depth channel, it was smart enough to know that that's the only channel that isn’t RGB, so that's probably the one we want to use. But you can change this as well. If you have more than one channel, you can select the one and this is also another good reason to name your channel. I know that depth is the one I created, so that's the one I want to use. So what it's doing is very similar to what the depth blur neural filter is doing is it's using that depth channel to determine what's in focus and what is out-of-focus in your image. But with lens blur you do have more options. And also the interface is a little more intuitive here. I can simply click on what I want to be in focus, and then it’ll adjust the focus accordingly in the image. So here, if I want this right here to be in focus, I just click on it and you can see it's processing that's in focus. Everything else is out. If I want the car to be in focus, I click on that and you can see because I have this depth map, it's doing a really good job of creating realistic depth of field. Now here you can also adjust your blur focal distance. And actually as I click this, you can see that it's changing that. So interactively, it's adjusting this focal distance. You can also invert that if you want to. But next we have these iris options and these are really helpful to create a more realistic depth of field. So the iris shape, the iris is the aperture in your camera and it gets bigger and smaller to allow more or less light. And the way that aperture is created is by using blades. And those blades there's usually six or eight in the lens you're using, but you also have a few creative options here. So if I go on triangle and you look at these little highlights here, you can see that as they're going out of out of focus, the light spots are also turning into these triangles. Now, I'm going to go ahead and zoom in by just holding down the spacebar and then the command bar and the spacebar at the same time. And then just clicking here in my image a couple of times until I'm zoomed in, if you want, you can also zoom in using these options down here. But I just want to show you these triangles a little bit closer here. So with the blade curvature, you're basically adding a curve to these three edges. So if I put this to 50 around 50, you'll see that it's added a curve to those made them more circular. If I go all the way to 100, it almost turns it into a circle. So that's what blade curvature does. I’m going to take that back down to zero. And then rotation rotates this triangle. So if I click here and start sliding this, you can see those rotated there and there you go. Okay, so that's what those two are. I'm going to put the rotation to zero. The blade curvature is zero and I'm going to take my shape and change it back to the hexagon just because that's what most lenses are. It's going to look most visually like this was taken with a camera. The next thing here is you have your specular highlights. So this the threshold determines which of the highlights are being highlighted. So let's go ahead and put this on 50 and you'll notice that almost nothing changed. And that's because our threshold is so low or so high. So as I started moving this down, let's go ahead and put it on to 28, wait for it to process. And there you can see what it's doing. So it's taking all of the lights in my scene and adding this specular bokeh highlight to them. Now, this might be the look you're going for. I don't particularly like it for this image. It's just adding too much color. So I'm going to take my brightness down to zero. Okay. And then finally you can add some noise. Personally, when I'm working on any image in Photoshop, the more I can keep things in layers, the better. So I would rather add noise as a separate layer in Photoshop. I'm not going to do it here, but this gives you a good idea of how to add that depth. So let's hit okay here and you can see here is the before and the after and we've created some nice blur depth to our image. Now the other thing we can do with our depth map is we can also create atmospheric depth or fog to our image. So let's go ahead and turn off our depth of field. I'm going to take my background, make another copy of it and we can call this one fog depth. And here I'm going to take my depth layer. Now if you deleted this for any reason, what you can do is create a new layer, call it fog, and then go up to image, apply image, and then just scroll down here from RGB to your depth channel and you can see that just takes that information and puts it in your layer. You can hit okay there. So that's just another way to get a channel into your layer. And then what I'm going to do with my fog is put it on screen. And now because the black parts are closest, the camera and the white parts are the furthest from camera. You get this very realistic looking fog where the further away it is, the thicker the fog is, the more white it's adding to the image. Now, I can adjust this by adding a curve layer here, and I want this curve to only adjust my fog, not all the images below it. So what I'm going to do is I'm going to click on this, a little icon here, and that'll clip this curve adjustment to this fog. The other way to do that is hold down option or alt and just click between the two layers. All right. So once it's clipped, what I'm going to do is take the bottom, my curve, which is the black part here, and then drag this to the right. And as I do that, you can see the fog is receding backwards away from the camera. So nice interactive way of adding this fog. We can adjust that if we want in here. I want the fog to basically or sorry, I want the fog to basically come up to these two cars here so I can just move this back until the fog is right around that level. You can see now the fog is back here, but it's kind of missing these two cars here. And that's what I want. And the other thing you can do here now, because this layer is also adding this lightness, we can go to our channels and give it a bit of color. So in this case, I want to give it a bit of a blue color. I want to create almost a wintery scene. So I'm going to go to my reds here. The opposite of red is cyan. So if I pull down my red, it's going to add cyan. You can see right away that's creating a nice blue tone there. And then if I go to my blues, I can add a tiny bit of blue as well. So there you can see we have this nice blue fog. Let's go ahead and collapse our properties there. Now, as we did this, you can see that we have way too much magenta or red in our foreground. So let's go ahead and adjust that. I'm going to add another curve here. And for this one, I'm going to add actually, before I add my curve, what I want to do is go to my lasso selection here. So this is right there and just hold down option so that I have my polygonal lasso and then I'm going to just go here kind of where the magenta areas in the foreground here, so something like this. And then I'm going to add my curve. And the reason you want to do your selection first is now when you add your curve, that selection will be built into the mask here. Now I can go to my red, pull that down so we get rid of that magenta. I can also go to my green. The opposite of green is magenta. So if I lift my green just a tiny bit, you're going to see that's also getting rid of that magenta. You can see if I go down, it's adding magenta, it's taking it away. Now this is pretty subtle, so I might just want to bump this up maybe one point. So very little there. So from 128 to 130. And then finally we can also go to our blue. As you can see, this has a little bit too much yellow. The opposite of blue is yellow. So if I pull up the blue, it's going to get rid of some of that yellow. And there you go. That looks pretty good in terms of a color. The last thing I want to do here is because I've added fog to my scene. The lights themselves would be coloring that fog. So I'm going to go ahead and add another layer and we're going to call this fog lights. And here I want to have a nice contrast to the blue. So I want to give it kind of an orange color. So I'm going to go to here, go to kind of an orange color, a little bit more yellow. So something like this, that'll be a good starting point. Then I want to go to my gradient tool. I want to make sure that under basic here I'm using the middle one, which is my foreground color gradient to transparent. I want to make sure I have my radial gradient selected, which is the second one here. And then I zoom in here. Also make sure your transparency is turned on. If I go from the middle of my light out, that's going to add that yellow light there. And let's go ahead and do that to a few of these lights. And as I'm getting farther away, I'm making my little gradient smaller. And the closer they are, the bigger. Okay, so that looks pretty good. Let's put this on screen and you can see that they're a little bit too bright. So to adjust that, I'm going to go to image adjustments and then hue saturation with hue saturation, just going to put the saturation to 100 so that as I start making it darker, it's also not making it grayer. And I'm going to move this to the left. I think about minus probably around -20. Looks good. Let's do a preview. So now it's just making those more colorful and less and not adding as much white to our scene. I think we can also push them just a little bit more toward red. So I'm going to take this and maybe minus it by three and I'm happy with that. Let's hit. Okay. And then finally, this whole bottom area feels a little empty, like there's not much happening. But I do see these hints of light here, so I see a little bit of light there, light reflecting there. I think it might be nice to accentuate that. So let's go to our lasso tool. And here I'm just going to make some pretty rough selections of this lighted areas. It's kind of hard to do this with a mouse, so what I'll do is I'll hold down option. Just do this area here and then hold down shift. So I'm adding to my selection. And then after I've started making the selection, I can let go of shift and then I can hold down option and that I'll switch to my polygonal lasso. So something like this and then again hold down shift. So I'm adding to my selection like go shift, hold then option to get my polygonal lasso. And then one last time here and then we also have these lights right there. So I'll just hold down shift, make a little circle around there and a little circle around there. So next we're going to go and add a curve. Now, as I mentioned, when you have a selection and you add a curve, it's going to create a nice mask for you. So here I want to bring this up so we have more light in those areas. And then I want to go to my reds, add a little bit of red and then add good to my blues and take that down. That's going to add a little bit of yellow. Now, if I want to add yellow without making my image darker by pulling. So anytime you pull your curve down, it's making your image darker, right? So this is adding yellow, whereas I kind of want to add yellow but almost screened. So to do that I would basically take the other two colors, red and green together, make a yellow. So if we go red up a little bit and then green up a bit, we're going to create yellow, but a lighter yellow. So something like that. I do still think we can add some yellow, so we'll just go here. Okay. So that looks pretty good. I mean, it looks terrible, but it's a good starting point. Next, we're going to go to our curve properties or sorry, our mask properties. Just add a little bit of feather until we get rid of these hard lines. All righty. That's looking better. All right. Now I feel like this doesn't have enough red. So let's go to our red and just add a little bit more red there. I kind of want it more orange, not lime green. So something like that. Okay. And then finally, just to make this integrate a little bit better, what we'll do is I'm going to call this light. Light reflections, a double click on the right side of our layer here. That's going to bring up our layer style and our blending options. And we want to go to this "blend if" and "blend if" is a great little tool in Photoshop that allows you to blend based on the luminosity of your layer or the layers below it. So in this case, I want to blend the light, these light areas so that they aren't affecting the dark areas, they're only affecting the light areas that are already there. So in that case, I'm going to go to my underlying layer. I want the dark side out of my blend. So I'm going to take this and start dragging it to the right and notice that it's starting to leave all the areas that are dark. You can see as I move it to the right, those areas are no longer being affected by that curve. So I want to do it until these kind of disappear and these start getting a bit lighter. So somewhere around there and the problem is if I zoom in here, you can see that there is no feather between 67 and then where it starts to lie, right? So as I move this, you can see it's almost like a threshold. There's no feather there. So what we can do to fix that is hold down option and then split this. So if I click now with option and then separate these a little bit on each side, we get a nicer blend. So something like that, maybe move this one even more to the right, get a little bit less of this in there. So something like that and then hit. Okay. And there you can see. So now this is just adding those nice highlights, adding a little bit of more of an interest or something to break up the monotony or the boringness of that bottom area there. And then finally, we might just do an overall color grade through the whole thing. Just pull it all together. To do that, I'm going to go to my curves and you can see here that our blacks are not black. So I might just pull this and kind of fix that and then maybe go to my blues, make my blacks a little bit blue like this, and then add a little bit of yellow to my highlights by pulling it down. Get that kind of nice look there. Generally, when I do this, I try to get the middle right here to cross in the same place. That way I'm not changing the overall colors. I'm primarily just changing my shadows and my highlights. So there you can see a before and after and you can see how much depth that adds to the image and creates much more of a background that you can add a subject to and that you might be wondering, well, what's the use of this when you're doing an image and it doesn't really help you in like a landscape photo, but we're really helps is when you have a subject and you want to separate that subject from the background. So let's go to file open. We're going to open this second file. So again, it's a very similar image with kind of just the street going back and the depth blur and the depth blur neural filter works best with images like this where there's an obvious perspective and kind of obvious depth. So something like this works really great. Now, as you can see with our black point and a black point is always whatever the blackest point is of your image is referred to as your black point. So if I go on to my eyedropper here, select this, you'll notice it's not really a pure black. So there's still two points of light here, but that gives you a good reference for what your black point is. Now, the further away in theory, there is more atmosphere, so your blackest objects are less black. And if I click here and then go to my black, here you can see now we have 17, 12 and eight compared to 2, 2, 2. And this is also quite a bit higher than it was in the last one, but not much. Right. It's still pretty black here compared to here in the foreground. And that's because there's not a lot of fog or atmosphere in the sky or in the air. So what I want to do is I want to put a subject here, but then I want to add some depth to the image so that our subject stands out. So let's go to file open. We're going to open this 03 and this is the subject we're going to take and put into that other image. So first, we can go to any of our selection tools here and then you'll notice the select subject here. You can also go to here and then select subject, but with here you have this little dropdown that gives you this option of cloud. I find that does give you better results. So I'm going to click on that and then click on Select Subject. This might take a second or two, depending on how good your Internet connection is, because with the cloud, what it's doing is it's sending that information to the artificial engine in Adobe and then processing that information. So you get a bit of a better result than your device, which is doing it using your computer's processor. Okay. So we have her selected. I'm going to do Command J to put her on her own layer. We'll call this woman and what I want to do here is I also want to rip off her shadow here. Creating a shadow for a person standing on a ground is always a bit rough. Getting it to look completely realistic is always a challenge. So if you do have a nice ground shadow as we do here, you're much better off just stealing it. So what I'm going to do here is I'm going to take this area that kind of represents where her shadow is to something probably like this, maybe even there. And I'm going to copy that from her background with Command J Now doing Command J is the same as doing layer new layer via copy, right? So you're creating a new layer from whatever is in your selection. So that's what Command J does. You can see I now have that layer and if I option click on the eyeball, that's all that's in my layer. And what I'm going to do here is I'm going to go to my patch tool and with my patch tool I'm going to select these lines and just try to get rid of them. So we'll go here. And the option trick similar with the lasso tool also works here. If you hold option, it turns it into a polygonal lasso, rather than freehand. It's a lot easier for selecting lines so selected that line I'm going to do here is now just drag this up like so and you'll see it's getting rid of that line for me and we'll do that with all of these. And if you're wondering why we're doing this is because the image that we're pulling this shadow onto also has lines and we don't want to have competing lines. Okay, so that's probably enough. We're going to call this foot shadow and then I'm going to take both these layers. So hold down shift that allows you to select more than one layer at a time and then what I want to do is I want to take this and separate it so that it's a free floating window. Now, I can see both the image that I want to pull the layers into and this file at the same time. And here I can just take my layers and drag them into here. And there you can see it's put these layers in here now line up where I want her standing, which is about there and then do command t or edit free transform. And then I'm just going to take the top, drag this down to where I want her, which is about there maybe up a little bit about there. Okay. So there she is. I'm going to go ahead and convert her to a smart object and then for the foot shadow, I'll also convert that to a smart object by converting it to a smart object. Any filters that I add to it or even adjustments will be interactive—meaning, I can go back and change them if I want to. So here I'm going to go to image adjustments, curves. What I want to do is I want to just leave the shadow. So I'm going to take my white point, bring this up quite a bit, probably about there and hit OK. I'm also going to add a hue saturation and just get rid of all the color in there. And then I'm going to put this layer on multiply and then add a mask to it. Go to my brush, make sure my foreground color here is black, and then just with a soft brush at around 450 pixels, we'll just paint this edge away and then maybe I'll do a gradient again, put this on linear and make sure you’re on foreground to transparent. And then we'll just go from this side kind of toward where she's standing. And there you go. We have a pretty realistic shadow there. We didn't have to do much except copy it and put it on top. That's always going to be give you a better result than trying to make up what that shadow might look like. So if you can copy your shadow, always do. All right. And then for the woman with this scene, we have kind of a nice color scheme going with this slight blue colors and the gold color. I kind of like that a lot. And it's we have that gold color hitting her face as well. This pink color feels a little out of place. So I'm going to go to image adjustments, hue, saturation. And here I want to go to my magenta. So that's this range here and I want to start pulling that saturation down. And you can see the pink in her jacket is kind of starting to disappear. And I put this around -90. So it's taking the majority of the color out. And then if I want to see like maybe I can get a little bit more of the pink, I can move this to the right or left, but you have to pay close attention to the skin tones because you don't want those becoming desaturated. So it looks like right about here is the sweet spot where it's getting rid of most of that pink color, but not affecting her skin tones. Let’s hit okay there. Okay, so now we have our basic composite in place and this is where we're now going to use that depth to make her stand out from our background. So first, let's try doing a shallow depth of field and see what kind of result that gets us. So I'm going to go to my background, make a copy of it, and then go to filter neural filters. And I'm going to turn on the depth blur and let’s scroll all the way to the bottom, turn on the output depth map only and hit. Okay. And then I'm going to isolate this layer by holding down option or alt and clicking on the eyeball. So I just have my depth map. I go to channels and make a copy of it and call this depth. Go back to RGB, go back to layers, hold down option, click on the eyeball again, turn on all the other layers again, and then I can turn off this layer which will also call depth. Then I'm going to select my background again now where she standing is between this line and this line. So the reason I want to know that before I go into my lens blur, filter is because the lens blur filter isolates the layer that you're working on. So if we go to blur, lens blur, she's no longer in the image, but I want to make sure my focal point is where she was standing because that's what's going to be in focus. So I'm going to click on my focal point right between those two lines. And you can see that's throwing everything else out of focus. Now, if I want this even more out of focus, I can increase my radius here and that'll make it even more out of focus. I might even do something here where I am adjusting the threshold to get a little bit more, more bokeh into my image. So let's see what that looks like with just a little bit here. Let's see what kind of results we get. So maybe something like that looks we're using a lens with a very shallow depth of field. If I hit okay here, you can see right away she stands out from that background so much more your attention is more focused in on her and it just looks like a better portrait. Now, you might not want to use this much shallow depth of field, meaning you may not want the background this blurry because you don't want it to look like a miniature. But even with a little bit, you get that separation between subject and background. Now if you don't want to use any depth blur at all, that's where Atmos ferric fog or atmospheric depth can really help you. So here I'm going to turn off this depth of field and then let's make another copy of our background and we can call this one fog depth or atmospheric depth, whatever you want to call it. And here we're going to turn on our depth layer again and put this I'm going to put it so that it's with these two layers, and then we're going to take this and put it on screen and then we're going to add our curve layer, as we did in our previous project, clip this and then here I can adjust where I want that fog to be and really I just want the fog behind her so I can kind of take it back to maybe about there. So it's hitting the Cartier and then the rest in front of her is not so much out of focus. So I'm sorry, you know, without fog on it. So something about there I think looks good. You can also add a little bit of color to it, maybe a little bit of cyan. But in this case, I think actually it looks good without color. So let's just leave it like that. And the other thing I want to do here is now that I've added all this fog, she would also be a little bit brighter. So we can do that here. I'm going to add a curves layer and then clip it to her. Now, you might be wondering, why am I not just adding a curves layer here? And the reason for that is I want my curves layer to have its own mask separate from the smart filters mask. So here what we'll do is just take this up until she looks like she better belongs in this background. So about there, I think and let's go ahead and on my mask, I'm going to go to my gradient. You can see that here. Now, her black point doesn't match meaning it's too light down here. Can kind of see that in the black here and then the black here. That's a very small detail. But these are the kind of small things that really help add realism to your composite. So here I'm just going to take a gradient from the bottom kind of go to probably about here and then it'll just add that blackness back in here. So something like that. And there you can see if we take our depth, these layers that make our depth, put them in a group we can call this fog. If I turn that on and off, you can see what a difference it makes in terms of isolating our subject, making her stand out more. So both of these tricks you can do to add depth to your image and also make your subject stand out. And the trick to all of it is this neural filter and creating this depth mask that you can then use with the lens blur filter, or you can use to create atmospheric fog like we did here. So there you have it. That's how you can use depth maps in Photoshop to create depth and also to isolate your subject from the background. Now there's another way to use depth maps in Photoshop that I haven't thought of. Go ahead and mention it in the comments. Otherwise, like this video, subscribe to my channel, share this video, turn on notifications and here are some other tutorials that you can check out. I'll see you next time.
Info
Channel: Nucly • Photoshop and Creative Design Training
Views: 111,804
Rating: undefined out of 5
Keywords: photoshop, photoshop tricks, Nucly, Photoshop Tutorial, Photoshop Training, Adobe Photoshop Tutorial, Photoshop CC, Photography Tutorial, animated GIF, GIF in Photoshop, timeline, animation, timeline in Photoshop, creating a matte in Photoshop
Id: JvJkEg5BT9E
Channel Id: undefined
Length: 39min 3sec (2343 seconds)
Published: Wed Jan 11 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.