RetouchPRO

Go Back   RetouchPRO > Technique > Photo Compositing
Register Blogs FAQ Site Nav Search Today's Posts Mark Forums Read Chat Room


Photo Compositing Collage, montage, masking, selections, combining, etc.

Reply
 
Thread Tools
  #1  
Old 01-17-2006, 07:27 AM
Member
 
Join Date: Jan 2005
Posts: 74
Complex hair selection

Hi friends. Im trying to make a perfect selection this image. The image was shoot with chroma background (blue). I need remove background (blue) but I can not remove blue highlights in hair. I have primatte chromakey (digital anarchy) but dont remove spill (blue) in hair. Anyone know a good method?
Thks
Attached Images
File Type: jpg hair.jpg (99.8 KB, 326 views)
Reply With Quote
  #2  
Old 01-17-2006, 07:50 AM
byRo's Avatar
Moderator
 
Join Date: May 2004
Location: Goianésia, Brazil
Posts: 1,592
I would convert to LAB mode and have a look at the A and B channels.
Duplicate the layer and run levels on one (or both) of the channels marking a black point on the background and a white point on the hair.
You should be able to make a pretty good mask combining these two channels.

Reply With Quote
  #3  
Old 01-17-2006, 12:00 PM
Member
 
Join Date: Mar 2005
Location: Montreal
Posts: 45
Hi
This is how I would approach this: http://byloc.com/hair-extract.jpg

1. Original Image
2. Mask made using calculations. (Multiplied the inverse of an enhanced red channel into an enhanced blue channel.)
3. Result of applying that new alpha channel to the hair, we can clearly see the blue highlights.
4. Mask made with calculations by substracting the blue channnel with the red.
5. Result after using that second alpha channnel to mask a level (or curves) ajustment layer that subdued the blue cast.

Note that you can get much much bettter result if the file has better resolution and less jpeg artifact that the one that was posted. Hope this helps, good luck!

Last edited by meok; 01-17-2006 at 12:10 PM.
Reply With Quote
  #4  
Old 01-17-2006, 12:39 PM
Member
 
Join Date: Jan 2005
Posts: 74
Quote:
Originally Posted by meok
Hi
This is how I would approach this: http://byloc.com/hair-extract.jpg

1. Original Image
2. Mask made using calculations. (Multiplied the inverse of an enhanced red channel into an enhanced blue channel.)
3. Result of applying that new alpha channel to the hair, we can clearly see the blue highlights.
4. Mask made with calculations by substracting the blue channnel with the red.
5. Result after using that second alpha channnel to mask a level (or curves) ajustment layer that subdued the blue cast.

Note that you can get much much bettter result if the file has better resolution and less jpeg artifact that the one that was posted. Hope this helps, good luck!
Great work meok, but I dont understand step 2 and step 4, anyone can explain it more in detail?

Last edited by superfrasky; 01-17-2006 at 01:58 PM.
Reply With Quote
  #5  
Old 01-17-2006, 02:37 PM
Member
 
Join Date: Jan 2005
Posts: 74
I need help.... I can not remove blue background and blue hair highlights....HELP, HELP,HELP
Reply With Quote
  #6  
Old 01-17-2006, 03:04 PM
Cameraken's Avatar
Senior Member
 
Join Date: Feb 2005
Location: Lancashire (UK)
Posts: 1,122
Hi Superfrasky.

Meok provided a great method which works fine on this picture. However there is perhaps a more useful method here which works on most images.

http://www.russellbrown.com/tips_tech.html

And Larry provided a great explanation here

http://www.retouchpro.com/forums/photo-compositing/11544-extraction-new-background-new-trick.html

Larry painted out the colour Before the extraction but it can be done after with a layer set to colour and applying the same mask. It can look more natural if you add some colour from the new background.

Hope this helps.

Ken
Attached Images
File Type: jpg Ken_hair-copy.jpg (98.1 KB, 243 views)
Reply With Quote
  #7  
Old 01-17-2006, 04:10 PM
Member
 
Join Date: Jan 2005
Posts: 74
thks cameraken, but meok method I think that is good for this image. the problem is that I dont know how make him (2 and 3 step of method)
Reply With Quote
  #8  
Old 01-17-2006, 04:39 PM
Cameraken's Avatar
Senior Member
 
Join Date: Feb 2005
Location: Lancashire (UK)
Posts: 1,122
Hi Superfrasky.

I think Meok must have a few extra steps. I don’t really understand calculations.

OK. I’ll try and learn with you.

Dupe the Red Channel
Dupe the Blue Channel

On the Red Copy Channel adjust levels
0 1.00 172

On the Blue Copy Channel adjust levels
0 1.00 213

Select Image > Calculations

Source 1
Channel Blue Copy

Source 2
Channel Red Copy Invert Checked

Blending Multiply

Click OK

This makes a new Channel, Alpha1
Image > Adjust > Invert
Adjust Levels
30 1.00 192

This gives something very similar to Meoks Second Picture.




Ken
Attached Images
File Type: jpg Ken_Pic2.jpg (36.2 KB, 135 views)
Reply With Quote
  #9  
Old 01-17-2006, 05:12 PM
Junior Member
 
Join Date: Jan 2006
Posts: 8
are you using photoshop or paintshop pro?
Reply With Quote
  #10  
Old 01-17-2006, 05:57 PM
Swampy's Avatar
Senior Member
 
Join Date: Feb 2005
Location: The Swamps of Florida
Posts: 4,416
This was a challenge, but here's what I came up with.

Basically did a H/S to put some more color in the hair first.

Used the red and green channels combined (see the great calculation tutorial above, Thanks, Ken!) to generate a mask

Inverted the mask and deleted the blue background.

Used Photoshop's Color Replacement tool (Under the Heal brush) to replace any remaining blue spill. You can go back into Curves and soften the whole thing to more closely restore the ash blond (original) colors.

This looks best on a dark background.
Attached Images
File Type: jpg swampy-w-hair.jpg (34.0 KB, 153 views)
File Type: jpg swampys-b--hair.jpg (31.9 KB, 210 views)
Reply With Quote
  #11  
Old 01-17-2006, 06:35 PM
byRo's Avatar
Moderator
 
Join Date: May 2004
Location: Goianésia, Brazil
Posts: 1,592
I read through meok's method and it's pretty much the same as I did here using the LAB channels.

1) Duplicate the layer;
2) Run levels on the A and B channels marking the background as one extreme (black / white) and the hair as the other;
3) Use Image>Calculations to form a new channel by multiplying the modified A and B channels (have to invert one of them);
4) Make a new duplicate of the original image and apply this channel as a mask;
5) Run Levels on the mask until you get the best possible masking of the edge hairs (don't worry about the inner hairs);
6) Paint the mask to show all the hairs away from the edge;
7) The hairs are now separated from the background, problem now is the colours - take a paintbrush set to blending "Colour" and sample from the "good" hair and paint on the "blue" hair. Vary the sample to get a few differente hues;
8) Put in your new background.

Attached Images
File Type: jpg Hair-byRo.jpg (98.6 KB, 214 views)
Reply With Quote
  #12  
Old 01-17-2006, 07:41 PM
Cameraken's Avatar
Senior Member
 
Join Date: Feb 2005
Location: Lancashire (UK)
Posts: 1,122
Quote:
Originally Posted by Swampy
(see the great calculation tutorial above, Thanks, Ken!)
Ha Ha. Swampy. That wasn’t a tutorial. That was a complete Guess based on Meok’s method. I have read loads of things about calculations and still don’t understand it.

I understand how to use it. But I don’t understand which channels I should be using or Why and I don’t understand which blending mode to Choose. I guess it will come with practice.

Rô. Your picture looks great.
Using Russell Browns method (as I did in my first post here) some of the stray hairs look very ‘fat/thick’.

I will try your method.

I still think Leuallen’s method of changing the colour of the stray hairs to the colour of the new background Before making the selection makes a lot of sense.


Ken
Reply With Quote
  #13  
Old 01-17-2006, 11:52 PM
bart_hickman's Avatar
Senior Member
 
Join Date: Nov 2005
Location: Oregon, USA
Posts: 472
For step 2, he multiplied the inverse of the red channel and the non-inverse of the blue channel. Both the red channel and blue channel were enhanced prior to multiplication. You could enhance them as needed (curve, channel mixer, etc..) to get good contrast. This can be done interactively using adjustment layers rather than layer arithmetic.

For step 4, he subtracted some percentage from the blue channel and replaced that with an equivalent percentage from the red channel. This works because the hair has roughly equal red and blue channels. Again, I found that the channel mixer was more interactive for this step--go to the blue channel, set blue to 20% and red to 80%.

Very educational.

Bart
Reply With Quote
  #14  
Old 01-18-2006, 12:24 AM
Moderator
Patron
 
Join Date: Dec 2005
Posts: 2,852
Hair selection using LAB

I simply converted the orig image to LAB and selected the B channel (most contrast) and duplicated it. Then using the Apply Image command, applied the B channel to itself in Overlay Mode. A simple levels adjust to boost the contrast and the mask was pretty well done. Like Ro, I painted away the blue in the edge hair. Regards, Murray
Attached Images
File Type: jpg Hair Rev MM Thumbnail.jpg (78.3 KB, 151 views)
Reply With Quote
  #15  
Old 01-18-2006, 01:27 AM
Kraellin's Avatar
Moderator
 
Join Date: Apr 2005
Location: somewhere over there
Posts: 8,736
Blog Entries: 4
if i understand what you want, you want to remove the blue background, but save the blue highlights in the hair? is this right? that's how i read it, so i did this:

craig
Attached Images
File Type: jpg hair-1-k-1.jpg (96.0 KB, 131 views)
Reply With Quote
  #16  
Old 01-18-2006, 01:41 AM
Flora's Avatar
Moderator
Patron
 
Join Date: Mar 2002
Location: Milan, Italy
Posts: 2,274
Blog Entries: 3
Hi,

great tips and results!!!!

The problem in these extractions (plain flat colour background), for me, is not so much masking and extracting .... (here, because of the 'flyaway hair', I followed Russel Brown's excellent 'Advanced Masking' technique and I had a very acceptable mask in no time at all using duplicates of Green and Red Channels in RGB Mode.... ) .... but minimizing/removing the 'leftover colour cast' from the previous background around the edges of my selection.
As usual, there are many ways for doing this, but sometimes it can lead to a nearly complete desaturation, or a rather flat and 'monochrome' colorization ... and, in both cases, the natural difference in colour shades and highlights gets lost .....
I've been 'experimenting' with this and found that a combination of Hue&Saturation and Selective Colors Adjustment Layers helps a lot...
Attached Images
File Type: jpg F_hair.jpg (99.2 KB, 108 views)
File Type: jpg SNAP-0069.jpg (34.9 KB, 72 views)
Reply With Quote
  #17  
Old 01-18-2006, 01:52 AM
Flora's Avatar
Moderator
Patron
 
Join Date: Mar 2002
Location: Milan, Italy
Posts: 2,274
Blog Entries: 3
Craig,

it seems you posted while I was still writing my answer ....
Quote:
you want to remove the blue background, but save the blue highlights in the hair?
... actually, what superfrasky wishes is to get rid of the blue highlights in the hair after changing the background ....

P.S. I work with PS.
Reply With Quote
  #18  
Old 01-18-2006, 10:01 AM
Flora's Avatar
Moderator
Patron
 
Join Date: Mar 2002
Location: Milan, Italy
Posts: 2,274
Blog Entries: 3
I've just tried something different with this picture ...

No masking whatsoever (at least not in the conventional way)

I'm out of the house now, but if interested I'll explain later ...
Attached Images
File Type: jpg F_hair2.jpg (99.0 KB, 131 views)
Reply With Quote
  #19  
Old 01-18-2006, 12:18 PM
Kraellin's Avatar
Moderator
 
Join Date: Apr 2005
Location: somewhere over there
Posts: 8,736
Blog Entries: 4
flora,

i looked super's posts over again and i think you're right. when he said 'i cannot'' it could have meant 'i cannot because of a restriction from the boss or client' or 'i cannot because i dont know how to do this'. so, i wasnt sure. but, i believe you're correct.

and, you shld know by now that we ALWAYS want to know how you do things! as i've said before, you set the mark that we almost all aspire to, and certainly at least that i do. i even bought elements 4 to see if i couldnt approximate your examples a bit better and learn what all those words like 'transform' really are. so, yes, we want to know

craig
Reply With Quote
  #20  
Old 01-18-2006, 05:02 PM
Gary Richardson's Avatar
Moderator
 
Join Date: Mar 2004
Location: Yorkshire, England
Posts: 2,717
No masking. I'm intrigued Flora, do explain.
Reply With Quote
  #21  
Old 01-19-2006, 01:06 AM
bart_hickman's Avatar
Senior Member
 
Join Date: Nov 2005
Location: Oregon, USA
Posts: 472
The best way I've found for dealing with color cast like this is to use a channel mixer (set to monochrome) to create a mask that selects the area of color--turn up the blue and turn down the green and red). This makes an image (alpha-channel-to-be) that is black everywhere except where the blue is. The stronger the blue, the brighter it is.

Take this image and paste it into ANOTHER channel mixer (effectively masking its effects and constraining it to the blue fringe area.). The levels on this second channel mixer will turn down blue and slightly green, leave red the same.

This effectively replaces meok's step 4 while maintaining the interactivity of a channel adjust layer and avoiding hand-brushing.

I attached the last three steps--1. blue fringe, 2. masked channel mixer layer, 3. blue removed with masked channel mixer. Hair colors are unaffected.

PS--oh yes, and just like everybody else, I'm dying to see what Flora did too.

Bart
Attached Images
File Type: jpg blue.jpg (28.7 KB, 63 views)
File Type: jpg masked_channel_mixer.jpg (23.0 KB, 94 views)
File Type: jpg blue_gone.jpg (27.8 KB, 91 views)
Reply With Quote
  #22  
Old 01-19-2006, 07:55 AM
Member
 
Join Date: Jan 2005
Posts: 74
Thanks all by suggestions, very useful....really THANKS!!
Reply With Quote
  #23  
Old 01-19-2006, 03:42 PM
Moderator
Patron
 
Join Date: Dec 2005
Posts: 2,852
I also found a way to get there without a mask.
1. Convert the image to LAB
2. Add ablank layer on top
3. Fill the blank layer with solid black
4. Double - click that black layer to bring up the Layer Styles control panel
5. Go to the Blend If pull down box and select the B channel
6. Drag the highlight triangle (white) on the bottom layer from the far right to the center. When you get to the center Alt + Click the triangle to split it and the slowly drag the left half of it to the left (toward blue) until all of the whispy hair gets captured but the blue background is still supressed. Click OK
7. Flatten the image (you are still in LAB color).
8 Ctrl M to bring up the Curves control panel. Lock down the Yellow portion of the slope with at least 3 pts from the centre to the top so that the top half will not move when you do what comes next.
9. Take the lower half of the curve and flatten it completely so that it is lying flat on the X axis.
The results seem to be more fine and more accurate in capturing all the whispy hair than any of the other methods I have tried.
Regards, Murray
Attached Images
File Type: jpg Hair Rev MM Blend If Final Thumb.jpg (95.3 KB, 65 views)
File Type: jpg Hair MM Blend If Screen Shot.jpg (92.0 KB, 99 views)
Reply With Quote
  #24  
Old 01-19-2006, 06:45 PM
byRo's Avatar
Moderator
 
Join Date: May 2004
Location: Goianésia, Brazil
Posts: 1,592
Murray, that's a very neat method.

Just throwing in another quickie here, using the fact that this is a ChromaKey background......

- Click the eye-dropper on the background;
- Make a new solid colour layer (will be in the background colour);
- Set mode to difference;
- Inspect the result to find a good combination of channels for a mask (Red is good here)

etc.....

Reply With Quote
  #25  
Old 01-19-2006, 08:47 PM
Moderator
Patron
 
Join Date: Dec 2005
Posts: 2,852
Ro, thanks. Afterward I found that by pulling the right half of the split triangle back toward the yellow side I was able to define catch effectively all of the whispy edge hairs as they are in the original. BTW, your last technique is neat as well.
Best Regards, Murray
Reply With Quote
  #26  
Old 01-20-2006, 12:00 AM
Flora's Avatar
Moderator
Patron
 
Join Date: Mar 2002
Location: Milan, Italy
Posts: 2,274
Blog Entries: 3
Simply Hue/Saturation...

Hi everybody,

superfrasky,

you are welcome! ... Glad we could be of help ...

Murray,

great technique! .... I had actually written a Tutorial on a very similar selection method: Using "Blend If" for Selections and Selective Corrections. ... but never thought of adding a solid black Layer on top ... I have to try it.

Rô,

simple, fast ... great!!! Thank you!!

____________________________________

.... and here is my 'maskless' selection:

In spite of curls and flyaway hair, this picture is quite 'easy' to mask because of its clean contrast between subject and the strong flat colour background ...

After going through one of the conventional routines for masking, as I had done in my first post on this Thread, I simply tried to act directly on the 'colour side' of it ... meaning, I tweaked the background and 'halo' colours directly....

* I opened a Hue/Saturation Adjustment Layer and moved the 'Master' Saturation slider to 100% just to check what colours were where....and realized that background and 'halo' were made by Blues and Cyans ... (Attachment 1).

* ... so ... still working on my Hue/Saturation Adjustment Layer, I moved the 'Master' Saturation slider back to 0, went to the Blues and Cyans and tweaked them as in Attachments 2 and 3

* Attachment 4 shows the result I got with just a simple Hue/Saturation Adjustment Layer .... all curls and even the finest flyaway hairs are intact but cleaned from the bluish 'halo'.

After trying this on this particular picture, I've tried it on other similar images ... needless to say, it works best when the colour contrast is as strong as here or nearly so.
Attached Images
File Type: jpg SNAP-0070a.jpg (91.7 KB, 85 views)
File Type: jpg SNAP-0071a.jpg (78.4 KB, 102 views)
File Type: jpg SNAP-0081a.jpg (78.4 KB, 96 views)
File Type: jpg SNAP-0082.jpg (86.9 KB, 110 views)
Reply With Quote
  #27  
Old 01-20-2006, 03:03 AM
Flora's Avatar
Moderator
Patron
 
Join Date: Mar 2002
Location: Milan, Italy
Posts: 2,274
Blog Entries: 3
.... some more examples of Hue/Saturation background change ....
Attached Images
File Type: jpg SNAP-0081.jpg (98.4 KB, 98 views)
Reply With Quote
  #28  
Old 01-20-2006, 07:59 AM
Moderator
Patron
 
Join Date: Dec 2005
Posts: 2,852
Flora, Brilliant!
It is amazing how we often first approach tasks with a complex solution in mind when in fact there is a more elegant solution based on a fundamental concept that gets lost in all of the possible complexities. Thanks you for the additional enlightenment.
Best Regards,
Murray
Reply With Quote
  #29  
Old 01-20-2006, 09:05 AM
Gary Richardson's Avatar
Moderator
 
Join Date: Mar 2004
Location: Yorkshire, England
Posts: 2,717
Gotta agree with Murray, thanks for the breakdown Flora, an education as always.
Reply With Quote
  #30  
Old 01-20-2006, 03:06 PM
Member
 
Join Date: Jul 2003
Location: Loveland, OH
Posts: 88
Bart: may I ask for a little more help with the method you posted above? You listed the last 3 steps but I must need help with all the rest because I do not wind up with what you show, no matter what variations I have tried.

From your attachments, I seem to get the ColorMixer layer but I can not get the mask layer (that is below the CM layer) to look like yours. I could list my steps but am sure they are wrong or in the wrong order.

Can you elaborate or ask me what I should post to let you help me?

Thanks,

Ken
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Selection Tool T Paul Scratch Pad 2 04-15-2009 11:46 AM
Help removing complex hair from crazy background renato17 Image Help 16 11-24-2006 10:30 PM
Retouching Hair Strands - Does CS2 have a photo "TUBE" mode? ray12 Image Help 3 09-06-2006 09:39 PM
How to make a perfect selection of hair ? loornard Image Help 14 03-02-2005 03:30 PM
13 Photoshop Selection Tips DJ Dubovsky Photo Compositing 5 10-20-2004 08:49 AM


All times are GMT -6. The time now is 02:54 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.3.2
Copyright © 2008 Doug Nelson. All Rights Reserved