Jump to content

Extracting subject from green background


Recommended Posts

This is why we don't recommend using green at all for shooting images like this (unless, of course, you intend to have a portrait of a subject against a bright green background).  Getting rid of all the bright green in the hair and the veil is going to be a giant pain, to say nothing of the color casting (all those green reflections on the clothing and skin and hair!) and how difficult you've made it for yourself to mask or blend your subject against any other color at all...

But since you've already shot these images, and assuming reshooting them isn't an option...

Can you show us the background you want to use to replace the green?  

And while you're pulling that up, this tutorial might be helpful (though again, with the green, you've made this unnecessarily difficult for yourself).

Link to comment
Share on other sites

thanks for reply , i understand that, 

but i Didn't shoot these, m just editing, 
and m not replacing background, all i hv to do is cut the subject out.
m gonna go chq this link now,  
thanks again


Link to comment
Share on other sites

Ok, here goes ...

(Note: This method only works in Photoshop. If you had Elements, you'd be outta luck.)

1. Add a Channel Mixer layer and check the Monochrome box, and enter 0/100/0:


2. Add a Levels layer and bring the white slider in as far as you can to make the background pure white, but not lose too much hair detail.  This is a delicate balancing act.  It's a good idea to hold down the Alt key while sliding the slider, so you can have a good view of what's clipping.  Then do the same with the black slider, to fill in as much hair detail as you can, but not so far that you fill in unwanted detail too.


3. Invert the mask on that layer, then paint it only around the edges where it's needed - the hair and the veil in this case.  No need to be very precise with this painting step.


Here's the mask view so you can see a bit more clearly:


4. Add a white Solid Color layer, then a black Solid Color layer.  Invert the mask on both layers so they're hidden:


5. On the black layer, start painting to completely and carefully obscure the subject where she needs to be completely preserved.  Leave the wisps of hair to be wispy, of course.  I started with her head:


It's not a bad idea to turn all the other layers off sometimes, while doing this, so you're painting black over the original colour photo.  That's what I did while going around that tricky trophy thing she's holding:


To save your sanity, for heaven's sake make sure you use this method around the dress and other simple edges.

Eventually, the subject will be completely black:


I want to say that it's not vital to be accurate.  In fact, it's better if you allow a tiny bit of room inside the edge of the subject.  See how I've left a thin line of dress visible here?


6. Then paint on the mask of the white Solid Color layer, to make the whole background perfectly white.  This should be very quick, because around the hair it's already white, so no precision necessary, and around the dress, you can paint straight underneath the black layer you already did before.


7. Add a new blank layer (this might not be necessary in all versions, but this step can be a bit buggy, so do it anyway.)

8. Ctrl Alt Shift 2 (Mac: Cmd Opt Shift 2) to make a luminosity selection (gives you marching ants all around the white areas):


9. Turn off all the layers except for the Background layer. (You should still have the marching ants active).  Go to the Select Menu and choose "Inverse".  This will make the marching ants go around the subject, not the background:


10. Double-click the Background layer to turn it into "Layer 0", then immediately Ctrl G to put it into a layer group (remember, you should still have the marching ants while you do this):


11. Click the mask button in the Layers panel to add a mask to the group. The marching ants will disappear, and so will the background:


12. In the layer group, above Layer 0, add a new blank layer and call it "Colour Fix", and change its blend mode to "Color":


13. Temporarily close the layer group by clicking its little arrow.  Then add another white Solid Color layer and move it to the very bottom of the layer stack, below the group:


14. Then open the group again, and return to the "Colour Fix" layer you just made.  This layer will serve the same purpose as it does for fixing Chromatic Aberration.

When you zoom in, you'll see traces of green everywhere:


So you sample various nearby colours, and start painting over that green, like this:


Even the veil still has a hint of green tinge to it:


So you sample some purple colour and paint with low opacity to get rid of it:


The bottom is the worst - look at that awful green cast!


Sample and paint gently over it:


15. Finally, it should be done.  All the edges should be their correct colour.  You should be feeling proud of yourself right now

The last thing to do is change the bottom white layer to medium grey, and check the edges again to make sure everything's ok:


16. Then you can turn that bottom layer off, to see the photo in its transparent glory.

Then finally, go to the Image menu and choose Trim, and trim away the transparent pixels:


Leaving you with this:


Save that PSD for yourself. That's your master file if you need to come back to it.

17.  Finally, click on Layer 0, then go to the Layer menu and choose "Merge Visible".  Then delete all the layers which are turned off, leaving you with this:


Save that as a different PSD file, that's the one you'll send to your client.

Hope this helps.

  • Like 15
Link to comment
Share on other sites

Not as perfect as urs, 
But better thn i could ever achieve without throwing money on plugins, 
hope to improve it, 

Jus 1 last quetion, - Do u ever get tired of being amazing ? 




  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...