Welcome back to another very exciting tutorial here at the PhotoshopTrainingChannel.com.
My name is Jesus Ramirez, and you can find me on Instagram @JRfromPTC.
In this tutorial, I'm going to show you how to use Photoshop's Stack Modes to help you
remove tourists from your vacation photos.
This technique does require you to take multiple images and a bit of planning, but it is all
worth it in the end because the results are amazing.
The Image Stack Mode will take a statistical average of the content found in all the photos.
It will keep identical areas and remove everything that changes between the different shots.
It is very likely that cars and people would move and change locations, thus they will
be removed in the algorithm supplied leaving only the background.
When you're out taking the photos, make sure that your camera is on a tripod so that the
image is lined up better during the blend.
If you do not have a tripod, hold your camera as steady as possible when shooting your images.
Wait about 20 seconds or so in-between each shot.
You want to give people and cars time to move.
In most cases, you will only need between 8 to 20 photos.
In this tutorial, we're going to use 9 photos that I shot with my cell phone without a tripod.
For this video, I wanted to use photos that were not shot under the perfect conditions,
so that you could see the power of this technique.
And by the way, if you enjoyed this tutorial, don't forget to click on that subscribe button
and share it with your friends.
Okay, let's get started.
The first thing that we're going to do is bring in our files into one single document.
Each of the files is going to be a layer inside of that document.
And we can use a script to accomplish this task.
I'm going to go into File, Scripts, and select Load Files into Stack.
Then we can select either Files or Folders to bring into Photoshop as a single document,
so I'm going to select Folder, and I'm going to click on the Browse, then find the folder
that contains my files.
For me, that folder is here, and it's called Stacking.
You can download this stacking folder from my website.
If you want to follow along, my website is PhotoshopTrainingChannel.com.
There's a link to it right below this video.
So select the stacking folder and press OK.
Photoshop is going to load 9 different files onto this list.
Make sure that nothing else is selected, then click OK.
So Photoshop creates a new document and each file gets placed in the Layers panel as a
separate layer, so we have 9 different layers, and the layer name is the file name of the
original files.
As you can see, there are 9 different images of the Tribune Building in Oakland, California,
and as you saw when I disabled the images, I was not using a tripod; I was simply standing
there holding my cell phone, and I shot 9 photos about 20 seconds apart, which gave
enough time for people and cars to move.
What I'm going to do now is align these images.
If the images are not aligned properly, this is not going to work.
Since we didn't use a tripod, I'm going to use Photoshop to align the images.
The first step is to select all the images.
You can select the images by clicking on the layer on top, and then, holding Shift and
clicking on the layer on the bottom or you can use the keyboard shortcut Ctrl Alt A,
that's Command Option A on the Mac, to select all the layers.
When all the layers are selected, you can go into Edit, Auto Align Layers and Photoshop
will automatically try to align these layers.
Simply click on Auto, and then, OK.
Notice that Photoshop align the images.
If I disable them, they all pretty much align.
It's not going to be a 100% perfect alignment because I was moving around and there is also
a slight change in angle and perspective, so it won't be a 100% match.
And you can actually see that if I zoom in, there's going to be areas that don't quite
match up, but that's okay.
We're going to crop that out later.
So with all the layers selected, they're still selected, if they're not for you, once again,
Ctrl Alt A, Command Option A to select them all.
With all the layers selected, I can right click to the side of any layer and select
Convert to a Smart Object.
This is going to put all those layers inside of the smart object.
If I double click on it, you can see that it opens up in a new tab and all my layers
are still there.
I'm going to close it for now.
A smart object simply allows us to apply filters and transformations non-destructively.
And one of the things that we're going to apply is a Stack Mode, so with the smart object
selected, I'm going to go into Layer, Smart Objects, Stack Mode, and the stack mode that
we're going to use is Median.
This Stack Mode is going to look at all the pixels on all the images, and the pixels that
are constant throughout all or most images are going to stay, and the pixels that are
not constant are going to disappear.
Obviously, the background will not move, but the people and cars will, so the pixels will
be different.
That means that those pixels will disappear.
So watch what happens as soon as I select Median.
All the people and the cars in the background disappear.
If I zoom in, there's still a car there.
That car is parked.
Obviously, it didn't move throughout the different shots, but the cars driving by and the people
did.
And as I mentioned earlier, this wasn't a 100% perfect alignment, so we're going to
have some issues, but we're going to fix those towards the end of this tutorial.
And there's actually a faster way to get to this point and the reason I went the long
way was that you saw each of the individual steps to get here, but there's a command in
Photoshop that does all of this automatically, and I want to show that to you now.
I'm going to go into File, Scripts, Statistics.
Then under Use, select Folder, click on Browse and find the same folder once againóthe stacking
folder.
Select it, press OK and this is going to look very familiar.
You're going to see the 9 files there, but this time, select "Attempt to Automatically
Align Source Images."
And under Stack Mode, select Median and press OK.
So Photoshop will automatically open up all those images into one document as layers,
align those layers, and apply the Stack Mode, all with that one single command.
So as you can see, the difference between the two images is nothing really.
And, actually, let me fit this image to screen and then switch between both images so that
you can see they're exactly the same.
So that is the shorter, faster way of doing it.
And, again, I wanted to show you the long way so that you knew what the steps were in
case that the short version gave you some problems, you know how to backtrack and try
to figure it out, but, anyway, this is the final result.
At this point, you can work with either file.
I'm just going to close the new file but both files are the same.
So we're working now with one document.
What I want to do now is fix some errors.
This is a fantastic script, but the problem is it doesn't work great with background elements
that are constantly moving, background elements such as water or flags.
If you zoom into the top of the image, you'll see this American flag and it doesn't look
very good because it was waving, so when the stacking mode was applied, it sort of shopped
that up as you can see there.
There is also a smaller flag here on the bottom left.
So let me show you how you would fix an issue like this.
I'm going to zoom out and I'm just going to pan a little bit.
Then, I'm going to double-click on the smart object.
You can tell this is a smart object by looking at the bottom right of the thumbnail.
Double click on that.
It opens up a new tab and inside of this new tab, you'll see the 9 different files that
created that image, and if I disable them, I can go through all of them and see which
one has the best-looking American flag.
I like the flag in the 02.jpg layer.
I think it's the best one in this image, so I'm going to zoom in, click on the Lasso Tool,
and then click and drag around the flag to make a selection.
With Layer no.2 selected, press Ctrl C, that's Command C on the Mac, then go back into the
working document and press Ctrl Shift V, that's Command Shift V on the Mac, to paste in place,
and there's the flag; so this is before and after.
And you can, of course, do the same thing for the smaller flag.
I'm not going to do that to save a little bit of time, but it's exactly the same process.
What I'm going to do now is just look at the entire image just so we can see what we have.
And, obviously, we still need to crop it, but what I'm going to do before I crop it
is adjust the colors found on the image and I want to apply non-destructive effects, and
maybe even fix some of the distortion problems.
The distortion problems are not very big, but we could benefit from fixing them.
So what I'm going to do is select all the layers.
In this case, we only have two layers, I'm going to press Ctrl Alt A, Command Option
A on the Mac, to select the layers, I'm going to right-click to the side of those layers
and convert these two layersóthe regular layer and the smart objectóinto another smart
object, so Convert to Smart Object.
Now I can apply the Camera Raw Filter non-destructively, so Camera Raw Filter, and I'm going to use
the tonal sliders to adjust this image.
I'm going to click on Highlights and make the highlight darker, then click on Shadows
and make those brighter.
I'm sort of faking an HDR effect here.
Then I'm going to click on Clarity and drag it to the right.
This is going to add contrast in the midtones.
Then I'm going to click on Vibrance and drag that to the right as well.
This is going to add saturation to the colors found in the image that don't have a lot of
saturation.
It's sort of a smart way of saturating images.
Saturation applies a global saturation no matter what the current saturation of the
colors are, but vibrance protects the saturated color and only brings out the color and colors
that are desaturated.
Also, when you're working on portraits, vibrance protects skin tones, so it's one of my favorite
sliders to use to add saturation to images.
Now we're going to fix some of those distortion problems that I was talking about so you can
click on this icon here, which is the Transform Tool.
You can also press Shift T, and under Upright, you can click on the A button to apply an
Auto balanced perspective correction; so you can see the before and the after.
It's a slight correction, but I think it works.
Usually, distortions like these are more noticeable when you're working with straight lines and,
obviously, in this image, we have a lot of straight lines.
I'm going to press OK, and these are the smart filters here.
You can see the Camera Raw Filter that we applied.
You can click on this eye icon to disable the effect and click on the empty space again
to enable it.
The final step is to crop the image, so I'm going to click on the Crop Tool.
You can also press C on the keyboard and make sure that "Delete Cropped Pixels" is unchecked.
Usually, I don't like leaving this check box on just because I like to work non-destructively,
so I'm going to click and drag on these handles to better crop the image and hide some of
the errors here where the image wasn't aligning properly.
And I think something like this will work so I'm just going to press Enter on the keyboard,
and that's our final image.
That's it for this tutorial.
I hope that you enjoyed it and that you learned something new.
Make sure that you leave all your comments or questions down below.
If you create an image using this tutorial or any other of my tutorials, feel free to
share it on Instagram with the hashtag #ptcvids.
I often do a search for this hashtag to see what you're all up to.
If I find your image, I will leave you a comment.
Also, don't forget to subscribe and click on that Like button.
If you have a friend who you think will enjoy this tutorial, please share this link with
them now.
Thank you for watching, and I'll talk to you again soon.