Create a Content Aware Fill Action
now we're going to transition into actions in automation is there are some tasks in photo shop that you need to do repetitive Lee. And you either want to speed them up because the laborious multi step process is or you simply don't want to remember all the steps involved because sometimes they're things where you might need to use a sheet of paper to write them down. Why not just have Photoshopped keep track of the steps? So first, I'm gonna try opening an image here. This is a raw file. And in Kameron, I ended up correcting for lens corrections. There is a choice in here under the lens tab called Enable Profile Corrections. If I turned off, you'll see one part of the correction be changed. But this image was shot with a fish eye lens if I remember correctly and this is trying to straighten it in the process of straightening it, we ended up with some empty space that I don't want a crop out. So I'm gonna choose open image and I would like photo shop to fill those areas. Now the feature...
I would usually use to fill those areas is called content aware fill. And the problem is, I would like to fill those areas on an empty layer so that the filled in information is contained on its own layer. And Photoshopped doesn't like doing that. And to get around it, there's a multi step process, and I always I hate going through the process because it could should be such a simple process and it becomes more complicated. So I'm gonna create an action to keep it simple. So to access the actions panel, go to the window menu and choose actions that should get this to show up. You probably don't have as many actions as I do, but that's fine at the bottom. Let's create a new folder. If you click on the folder icon, I'm gonna just call this one ultimate guide actions. I'll click OK, and now we have a place to store our actions. We can organize them amongst the others and then at the bottom of the Actions panel. We have a bunch of icons, and I'm gonna click this one to create a brand new action, and I'm going to call this fill empty areas. I mean, ignore all the other settings that are here. We could add a color, which would literally make it have a color in the actions panel so you could organize. You're so creative actions or red and adjustment actions or blue or something like that. I find I don't need to. Here you could assign a function key, which would be the F keys that might be at the top of your keyboard, which would make it automatically apply this action. I don't need to do that in up here. The words set. That's what they call the folder. So this just means where we going to store it. And it's a list of all these folders. So in general on doing is naming it, and I'm clicking record. When I click record, watch what happens at the bottom of the actions panel. You'll find three icons on the left side of the actions panel that are used when you're recording and playing back actions, and the Round one will end up turning red men that indicates it is currently recording. Now, when you're recording, you have to be very careful at what you do in Photoshop. It's best if you practice ahead of time so that you know you can perform something flawlessly because any extra steps you put in are going to just slow down in action when it gets applied in the future. So you want to be very efficient. But I think I can remember what needs to be done here and so well, we'll see what I'd like to do here is first select the empty parts of this layer, and there's a trick that we've used a few times during the ultimate guide, where we loaded the empty everything except for the empty parts. What we did is we moved our mouths into the layers panel and I ended up holding down the command key, which is controlling windows, and I collect on this thumbnail image. When you do that, it selects all the areas that don't look like a checkerboard, and therefore it selects There is that are not transparent. I'll do that right now. When I do that, you'll find in the Actions panel. It just created a new step, and it's called set selection in Therefore win, this action gets applied. It should be able to create the same kind of selection. Now I want the exact opposite of that because I want the areas that are empty. So go to this select menu and I'll choose inverse to get the opposite. Then if I'm gonna use content aware, fill the selection that I'm using needs to be overlapping the image itself not just contained within that empty area. So I'm gonna go to the select menu, choose, modify and choose expand, and you can expand it. Just one pixel is fine. That simply makes it so. This selection will overlap the image itself by one pixel, Then usually, if I were to apply this to an empty layer, which is actually what I want to do, the content aware fill command will give me an heir message. That's just says there's not enough information on that layer for it to be able to handle things. So what I need to do is get a copy of this layer so that I'm working on Ah, copy in. So there are many different ways I could copy something. I could drag this down to the new layer icon and that would create a copy. Then, at this point, I'm going to go to the edit menu and choose Phil and I'm going to set the contents to content, aware I'll click OK in. That should be able to fill in those empty areas. But if you look at my layers panel, not only do we have those areas that are selected that just got filled in, but we have the rest of the picture and I didn't want the rest of the picture. So I'll go to the select menu and choose Inverse to get the opposite of it. And then I'm just gonna hit the delete key to throw away this middle portion of the image that we don't need. So now in my Layers panel, we have the original picture underneath and above it. We have just those areas that used to be empty that have been filled in all, then go to the select menu in Choose de Select to get rid of my selection. Now that's a process I hate going through every time because it should be that I could just tell it to fill the empty parts, and it should do all that for me. But it can. So in my layers panel, it's still recording. I need to hit the stop button to get it to stop recording, and then I need to test my action. I'm going to revert this image back to its original by going to the file menu and choosing Revert. I'm then going to click on the name of this action, which was called Fill Empty Areas, and I'll hit the play button at the bottom of the actions panel, and it should go through all those steps forming in filling the empty parts. And it seemed to work just fine. Anytime you create an action, you should look out the steps that were recorded to make sure that it's gonna be universally applicable. And the most common thing that happens with creating inaction is that if you ever switch which layer is active, it will usually record the name of the layer within the action. It will say, you know, make whatever the name of this layer is activist one of your steps, and if that's the case, the action will not usually be universally applicable because not every document will have a layer of that name. So let's see if we have anything within this action that looks like it might mess this up when I attempt to apply it to other images here. It says Set selection, Transparency Channel. I don't see the name of a layer within that. So I think that'll work fine. That simply means select the areas that are not empty in whatever layers active. Then we inverse the selection. Then we expanded by one pixel and I don't see the name of a layer in there. So we're fine here, It says. Duplicate current layer. Great. If it said duplicate, and then it's very specific layer name that wouldn't be universally applicable. We then we filled with content, aware looks good. He inverted the selection, hit, delete and then we set the selection and none. It looks to me like all those steps should be workable on any document. I don't see anything that's unique to this particular document, so I think we have a great first action