RetouchPRO

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


Photo Retouching "Improving" photos, post-production, correction, etc.

L*a*b* question: why can't it be simulated in RGB?

Reply
 
Thread Tools
  #41  
Old 09-09-2010, 08:22 PM
mistermonday's Avatar
mistermonday mistermonday is offline
Moderator
Patron
 
Join Date: Dec 2005
Posts: 3,028
Re: L*a*b* question: why can't it be simulated in

Andrew, OK, I also get where you were going so I guess the answer is yes, values should be the same but are way off. When you have real skin and the colors of good skin and a wrinkle or freckle are very close, and the lightness levels are not too far apart ( sometimes I call it a small dodge / burn distance), the gap in RGB is not very prominent and sometimes a Hue/Sat adj layer will close the gap. For some images with wide range of color and lightness variation, I prefer not to have the hassle.
Regards, Murray
Reply With Quote top
  #42  
Old 09-10-2010, 04:08 PM
Chain's Avatar
Chain Chain is offline
Senior Member
 
Join Date: May 2009
Location: Oslo, Norway
Posts: 551
Post Re: L*a*b* question: why can't it be simulated in

mistermonday; I'll explain my take on it again as you seem unable to match the values in RGB, while for me it works perfectly fine in both color spaces.
I have attached new updated files with this post so you can check what we do differently (since yours doesn't match we clearly do something differently). One of the new problems I found with the original test was that the two colors in the original test file had matching saturation and seemed to affect the results in some of my tests.

Starting point:
The orange ("good") area and the blue ("bad") area have clearly different brightness and color. We want them to match (to be identical).

Method:
In LAB we will do this by adjusting L and AB separately.
In RGB we will do this by adjusting "Luminosity" and "Color" separately.
(...adjusting the blue to match the orange)
The sum of the two components will give you any color value you want.
So you match first one component to the orange, and then the other.

Doing it (LAB):
1. In the LAB example file (I base this off my version) I create a curves layer set to Normal and adjust the curves to brighten the blue area until the blue and orange match in brightness.
It's hard to spot accurately enough by eye so for this test I use the Visualize layer as a visual guide and the L-value as a numeric guide (remember to have the sampler average a decent area to get a more useful value in a real photo).
2. I then sample some of the orange color, then I fill it in on a new layer above the blue area. Blending is set to Color.
I now have a perfect match between the left and right side. Check values.

Doing it (RGB):
1. In the RGB example file (I base this off my version) I create a curves layer set to Luminosity and adjust the curves to brighten the blue area until the blue and orange match in brightness.
I use the Visualize layer (set to color) as a guide. The L-value can work as a rough numeric guide but it's not perfect here as it measures Lightness and not Luminosity.
2. I then sample some of the orange color, then I fill it in on a new layer above the blue area. Blending is set to Color.
I now have a perfect match between the left and right side. Check values.

Notes and things to be aware of with the test files:
1. The "Visualize" (desaturating) layer is completely useless in this test if set to Normal blending mode in RGB.
2. If you do not dodge/color the entire blue area your brain might trick you into seeing an edge between the left and right sides even if the color values are identical. This is an illusion and wouldn't happen in a normal photo (at least not this strongly).
3. Make sure you have the top layer selected (make an empty one to be sure) when reading the color values from the samplers or Photoshop might give you a value based on whatever layer you happen to be working inside (a bit annoying).
4. In the images (both 16 bit) I've matched the color using the 8-bit values as with 16-bit it's just too fine an adjustment to get a perfect numeric match using curves that only have 256 steps.
5. In the RGB file if I swap the order of the Color and Luminosity layers the Luminosity layer will have to brighten the area a tad more to match. As long as I start with the bottom layer and work my way up the amount of work, as well as the results, are still the same. This does not happen in LAB so here LAB has a tiny advantage - but I don't see it having a practical effect.
6. Blending modes and adjustment layers work differently in different color spaces.
7. If the saturation was identical in the original colors (like in the first test mistermonday provided) the L-value worked perfectly in the RGB-test as a numeric guide when adjusting luminosity. If the saturation was different however the L-value was no longer to be trusted. The difference is small, so in a real photo with varying tone the L-value would be sufficient i believe.
8. The Luminosity/Lightness adjustment in a real photo would be done mostly by eye due to the variations in the image so we wouldn't be matching color samplers perfectly.

My conclusions are the same as for the example where I used a real photo example, but I did notice two very minor advantages in LAB that I only notice when working in this artificial test setting;
1. In LAB you can read the L-value while adjusting the L-curve. In RGB (if the color is wrong) there is no Luminosity-value you can read while adjusting the curves because the sampler won't give you a value that takes the above layers into account.
2. In LAB you can swap the Lightness and Color layers without any change, while in RGB this does produce a slightly different result.
The differences seem so minor that I think it's down to a matter of taste, and I rather prefer to keep all my tools consistent and available instead of juggling color spaces (converting/nesting) just for those two tiny improvements.

Hmm... Is it impossible to post in this thread without making a wall of text? :P
Attached Files
File Type: zip LAB and RGB test v2.zip (30.8 KB, 14 views)
Reply With Quote top
  #43  
Old 09-10-2010, 07:07 PM
mistermonday's Avatar
mistermonday mistermonday is offline
Moderator
Patron
 
Join Date: Dec 2005
Posts: 3,028
Re: L*a*b* question: why can't it be simulated in

Chain, thanks for your file and analysis. It appears that you have executed a Kobayashi Maru which, for those who are not trekkies, have modified the rules to escape a "no win" scenario.
Your curve is not a typical brightening curve. You pulled the center point up just enough to match the brightness of the left side. In real D&B the curve is much steeper. You have mitigated the problem in your first image by having a difference in lightness values according to the measuring device in the version 2 image. Your eyes see the brightness as identical, even though it is not. Remember that when you are looking at both sides of the image to compare them, you are looking at two sides of the same RGB image.
Notwithstanding these arguments, I will agree with you that in a real life image, with all of the anomalies, lines, micropores, and junk on most skin, the difference can be difficult to see. In the end, this may not be a worthwhile argument because I never said that good results could not be obtained in D&B in RGB.
So, let's park this discussion on D&B and conclude that RGB vs LAB comes down to personal preference with equal end results.
I will refer back to Andrew Rodney's question about what else I find necessary to do in LAB that can not be done in RGB. My next post will address such a topic. I will together a sample file and post it.
Regards, Murray
Reply With Quote top
  #44  
Old 09-10-2010, 11:27 PM
mistermonday's Avatar
mistermonday mistermonday is offline
Moderator
Patron
 
Join Date: Dec 2005
Posts: 3,028
Frequency Separation in LAB

If you do any retouching, you most likely use or are aware of frequency separated images and how useful and time saving they can be.
In LAB, you can make two types of separations, one of which you can not do in RGB. Below I have included a link to an RGB file - sorry, its 21MB. No pretty model for this exercise. I chose King so you have lots of fine texture to heal with, some light, some dark; some color and some white & gray.

After opening the image please toggle on/off the eyeball of the Symetric Freq Separation layer group. The view should look exactly like the background. If you open that layer group you will see a LF/GB layer and a HF/HP layer. The latter has been created with Apply Image rather than the traditional High Pass filter. It looks the same as a Freq Separation that has been created in RGB, with a Blurred layer on the bottom (LF)and a HF layer that looks like a mess of gray but it is actually a lot of gray with an abundance of fine edges whose colors are the same as the background image edges but much higher in contrast. And therein lies the problem with a Freq Sep. in RGB and for the same type of separation in LAB. When you clone or heal on the HF layer, you are copying and introducing some color along with the texture. As the Radius increases, so does the amount of color. When you use the Healing Brush to replace texture, you are bringing some color over. Normally in skin retouching this is not a major problem because you tend to heal texture from similar colored areas on skin. But you still need to be careful. Play around with this symetric group. Sample from King's redish brown coat and heal on his white mouth. Texture looks great but if you zoom in really close you can see hint of brown color. Try a sample from the tree or some hair of his gray mane, and you will see traces of green.
OK, now switch off the Symetric Group and toggle on/off the Asymetric Group. Again the view is exactly the same as the background layer and the radius of separation is exactly the same, BUT one major difference. The detail / texture has been completely separated from the color. Alt+Click the HF layer icon and you will see it has no color in it - totally grayscale. Now sample and heal all over the image with the healing brush and there is not a hint of color polution anywhere. Because there is no color on that layer.
At this point you may be saying to yourself " Why not just desaturate the HF layer in RGB or the Symetric separation in LAB to make the color go away?" No, that is not the same because once you do that you have destroyed the relationship between the LF and HF layers of the Frequency Separation (HP+GB=Orig) and view will no longer equal the original.
If you play around a bit with this asymetric split, you may also discover some other interesting and useful applications.
The file is located here
I hope King forgives me for retouching his skin.
Regards, Murray
Attached Images
File Type: jpg King After.jpg (165.0 KB, 50 views)

Last edited by mistermonday; 09-10-2010 at 11:36 PM.
Reply With Quote top
  #45  
Old 09-11-2010, 04:33 AM
Chain's Avatar
Chain Chain is offline
Senior Member
 
Join Date: May 2009
Location: Oslo, Norway
Posts: 551
Re: L*a*b* question: why can't it be simulated in

Quote:
Originally Posted by mistermonday View Post
Chain, thanks for your file and analysis. It appears that you have executed a Kobayashi Maru which, for those who are not trekkies, have modified the rules to escape a "no win" scenario.
Your curve is not a typical brightening curve. You pulled the center point up just enough to match the brightness of the left side. In real D&B the curve is much steeper.
Then I believe we were not clear on the rules.
In my version I did pull the curve to match the brightness I wanted. I could leave the curve at a steeper setting and adjust the mask until the brightness matches (if brushing on a real image this is closer to what would be done). It would give the same end result however...

Quote:
Originally Posted by mistermonday View Post
You have mitigated the problem in your first image by having a difference in lightness values according to the measuring device in the version 2 image. Your eyes see the brightness as identical, even though it is not.
I'm a bit unsure what you mean; I am not comparing anything between the two image files. The left and right side (in the LAB and RGB version) are identical not only to my eyes, but to the color sampler in Photoshop (8-bit). I'm not sure how you can say they are different - unless maybe you are comparing the LAB image with the RGB (and I'm not 100 % sure the orange is the same in those two)?

Quote:
Originally Posted by mistermonday View Post
So, let's park this discussion on D&B and conclude that RGB vs LAB comes down to personal preference with equal end results.
I agree with you here. Let's move on to the more advanced/interesting LAB-uses we can find. I will look closer at your frequency separation that keeps all the color out of the HF-layer. If you keep the HF layer gray then you have to have the HF color info left on the LF layer? I might be able to separate out this in RGB but I have not tried yet (as you mention you rarely sample from an area with a very different color).
Reply With Quote top
  #46  
Old 09-11-2010, 05:35 AM
Der_W's Avatar
Der_W Der_W is offline
Senior Member
 
Join Date: Jul 2009
Location: Germany
Posts: 558
Re: L*a*b* question: why can't it be simulated in

I like your idea, Murray :-).

Tried to replicate it in RGB and came to the following conclusion:

1. Duplicate your background layer thrice, name first copy "LOW" (mode: "Normal"), second "Color" (mode: "Color"), last "HIGH" (mode: "Linear Light").
2. Desaturate both the "LOW" and "HIGH" layers, fade both desaturations to "Hue".
3. Blur the "LOW" layer with GBlur.
4. Use "Apply Image" on the "HIGH" layer as you would with normal frequency separation.
5. Merge the "Color" and "LOW" layers.

That way you can - staying in RGB - have a LOW layer that contains all the color with a completely desaturated HIGH pass.

I've uploaded an action that does exactly this as well.

Edit: I remember that I had done a video on this long time ago: http://www.youtube.com/watch?v=2D2GZgUs9BQ
The only difference is, that you're merging the "Color" and the "LOW" this time.

Edit #2: I did a quick tutorial to show this technique: http://www.youtube.com/watch?v=uYFl4Gf3Qp4.
Attached Files
File Type: zip Experimental Techniques - Jonas Wendorf.zip (1.0 KB, 29 views)

Last edited by Der_W; 09-11-2010 at 10:51 AM.
Reply With Quote top
  #47  
Old 09-11-2010, 10:35 AM
Flashtones Flashtones is online now
Senior Member
 
Join Date: Apr 2009
Posts: 956
Re: L*a*b* question: why can't it be simulated in

Jonas, I just knew you'd have something to offer here.

I really like your method, so as to keep COLOR out of the HIGH layer. What I'm wondering is how advantageous it may be, or not, to keep the COLOR separate from the LOW (vs merging)? Is it useful or does it just add size/complication?
Reply With Quote top
  #48  
Old 09-11-2010, 10:56 AM
Der_W's Avatar
Der_W Der_W is offline
Senior Member
 
Join Date: Jul 2009
Location: Germany
Posts: 558
Re: L*a*b* question: why can't it be simulated in

Not merging the COLOR will give you some advantages, if you wish to blur the lower frequencies without affecting the color (so you can blur nearer to the edge without smearing color into it).
I don't see that much of a use in it, but that might be because of my style of working (that's why I originally presented this method in the OPR video, some might have a use :-)).

Hopefully this thread will continue to be a great source of inspiration for all of us (keep on guys!) :-)
Reply With Quote top
  #49  
Old 09-11-2010, 11:35 AM
mistermonday's Avatar
mistermonday mistermonday is offline
Moderator
Patron
 
Join Date: Dec 2005
Posts: 3,028
Re: L*a*b* question: why can't it be simulated in

Chain,
Quote:
If you keep the HF layer gray then you have to have the HF color info left on the LF layer?
, yes all of the color is on the LF layer.

Jonas, good job doing the separation in RGB. The results are identical.

Flashtones, there are advantages of the Asymetric separation but there may also be disadvantages. If you followed my post above you will see that in a symetric separation, healing from one area to an area of very dissimilar color introduces and blends in some of the sampled color into the new area. In actual practice, this does visible because you tend to heal texture from an area of similar color.
Healing on an Asymetric layer guarantees you only bring over texture only, however when you heal with texture where the source has strong contrast, you can also accentuate the edges of the destination where strong color exists. Attached are two examples where I sample the Hair from king's forehead and heal on the edge of his right ear. In the conventional symetric separation, it blends in nicely. With the Asymetric separation it blends very well but you also see the blue edge of the ear/sky interface become more visible. You will have different results if you use the clone stamp. BTW, effects are the same for each type of separation whether you do them in RGB or LAB.
I think the bottom line is that each method of separation could be used to advantage and it is good to have the ability to to use both of them.
Regards, Murray
Attached Images
File Type: jpg Symetric Screenshot.jpg (176.6 KB, 44 views)
File Type: jpg Asymetric Screenshot.jpg (168.8 KB, 69 views)
Reply With Quote top
  #50  
Old 09-11-2010, 11:41 AM
Chain's Avatar
Chain Chain is offline
Senior Member
 
Join Date: May 2009
Location: Oslo, Norway
Posts: 551
Talking Re: L*a*b* question: why can't it be simulated in

Seems the other Jonas got there before me (my name is Jonas as well :P). I would have tried something similar. Are you me from the future?

Seems I saved some time!

Time for me to make my own updated frequency separation actions. Hehe.
Reply With Quote top
Reply

  RetouchPRO > Technique > Photo Retouching


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
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
Converting CMYK to RGB and back to CMYK. xxxmen Input/Output/Workflow 23 01-06-2011 11:56 AM
my 1st post..red cast on Lacie 324/CS4 RGB to CMYK nadaman Hardware 47 03-10-2010 02:31 PM
Adobe RGB (1998) profile problem * Sinisa Software 7 07-10-2009 11:08 PM
RGB Help PSE JohnTravers Salon 5 10-13-2008 07:28 PM
silly question Tinkerbella197 Photo Restoration 5 09-15-2008 11:46 AM


All times are GMT -6. The time now is 10:11 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
Copyright © 2016 Doug Nelson. All Rights Reserved