Options

Curves 101

divamumdivamum Registered Users Posts: 9,021 Major grins
edited February 1, 2011 in Finishing School
Anybody want to take a crack at explaining this? I use them, I've done some reading and followed some tutes (eg the dgrin one for pop by setting new black and white points, and a few others that were part of a long chain of retouching processes), but I pretty much just followed the instructions and don't feel I understand the principles well enough, and consequently, how/when/where/why to use it.

Thanks in advance!
«1

Comments

  • Options
    jjbongjjbong Registered Users Posts: 244 Major grins
    edited January 23, 2011
    divamum wrote: »
    Anybody want to take a crack at explaining this?


    I'll take a shot.

    This is a very large topic. I'll talk about the principles of curves and
    show how this principles apply to one example - setting the white point.
    I'll assume that were in an RGB color space in 8-bit for simplicity.

    In this case, every pixel in the image is represented by three numbers,
    the Red, Green, and Blue values of that pixel. These numbers go from 0
    to 255. What a curve does is change these values.

    Take a look at a curves dialog box:

    1165604211_pptKi-O.jpg

    If you think back to high-school math, this is just a graph of a function.
    The function shows how the new pixel values are changed based on the old
    pixel values. In this case, the channel we're operating on is RGB. This
    is called the composite channel, and it means that we are going to transform
    the pixels in each of the R, G, and B channels identically. In effect, we
    are not changing the color, but only the brightness.

    The horizontal axis represents the inital value of the pixels, and the
    vertical axis represents the new value of the pixels. To see how a given
    pixel value is transformed, do something like this:

    1165602557_TAL67-O.jpg

    The red lines show how this curve takes a particular pixel value and
    changes it. In this case, it changes it to the same value.
    This is the curve displayed before you do anything to it (a linear
    curve), the value of each pixel remains the same. So there is no change.

    Here is a different curve:

    1165602592_96z6F-O.jpg

    This curve increases (brightens) each pixel (unless the pixel is already
    as bright as possible, that is value 255, or has a value to the right of where the curve
    flattens at the top):

    1165602667_zYrGY-O.jpg

    You can see by following the red lines that the changed value of the pixel is
    higher than it's original value. Two other things to note here. One is that
    a pixel with values of 0 in each channel (darkest black) will not be changed.
    The other is that the pixels are brightened the most if they are initially
    bright (high values) and are brightened the least if they are initially dark
    (low values).

    This is a curve you could use to set a white point. You set the upper point,
    moving the top of the line to the left so that the brightest spot in the image
    gets close to the highest possible value.

    Here is an example of an image that needs to have a white point set.

    1165604198_FJcZb-XL.jpg

    I used exactly the curve above to get this.

    1165604058_EGb2p-XL.jpg

    This image has a good black point. With the curve, I am now using the full range
    of brightness. The resulting image is both brighter and less flat (more contrast).

    This is a very basic example to illustrate the principles. It is not how I would
    do it on a real image, but I would apply the same principles in a different way.

    I'll just mention a few other related topics. You can use curves to adjust contrast.
    We did that here, as a side effect of setting the white point. But you can do it
    more purposefully. In general, you want the most contrast in the most important
    part of the image. So you want to set a curve with the steepest part covering the
    part of the image that's most important. Here it's the mission, which is in the mid-tones, and this curve
    does that:

    1165602584_gogRU-O.jpg

    The result is this.

    1165604087_dARJF-XL.jpg

    Note that the mission is much better, but note that the sky isn't as good. It's a
    zero-sum game. When you boost contrast in one place (here, the mid-tones), you
    lose it in others (darker and lighter areas).

    Again, this is for illustration purposes, and it is not how I would do it myself, but
    I would apply the same principles in a different way.

    Once you understand how to apply this, you can use the same technique to great effect
    on individual channels, and in other color spaces. Like I said initially, this is
    a very large topic.
    John Bongiovanni
  • Options
    jjbongjjbong Registered Users Posts: 244 Major grins
    edited January 24, 2011
    Since this post, I've been trying to come up with a way of explaining it that isn't too mathematical, and so far I haven't thought of any. Maybe others will.

    I think the fundamental problem is that the user interface (curves) is intrinsically a mathematical thing, you're dealing with a graph of a function, and you're modifying the function to do something. It's hard to explain it without the math. If you get the math, it's easy. If you don't, it's difficult.

    This is, I think, the attraction of the user interface in Camera Raw (and, I gather, Lightroom, with which I have minimal experience). You get some sliders like "Clarity" that effectively do a curve of a certain type, but you don't have to think about what it's doing. And that's not bad.

    You lose some flexibility, and you gain ease of use. It's all trade-offs.
    John Bongiovanni
  • Options
    RichardRichard Administrators, Vanilla Admin Posts: 19,931 moderator
    edited January 24, 2011
    There are many, many tutorials out there. John is correct that a basic understanding of math functions makes the whole thing easier to grasp, but it isn't rocket science and by playing around some you should be able to gain an intuitive grasp of how it works.

    It's best to use the RGB channel setting initially. Start by moving the end points of the curve up and down and left and right. Observe what they do to the tonality of the image. Then take the default line and add a single point in the middle. Drag it up and down and observe the results. Finally, do the same with a point one quarter of the way along the default line and then three quarters of the way.

    The key points to remember are: the points along the horizontal access correspond to the luminosity values of the underlying layer (input) and the height determines the result of applying the curve (output). The steeper the shape of the curve, the greater the contrast in that area of tonality.

    Once you fully grasp how the shape of the curve affects luminosity, you can then apply what you have learned to individual color channels, but that's a more complex topic.

    HTH.
  • Options
    colourboxcolourbox Registered Users Posts: 2,095 Major grins
    edited January 24, 2011
    jjbong wrote: »
    It's hard to explain it without the math. If you get the math, it's easy. If you don't, it's difficult.
    This is, I think, the attraction of the user interface in Camera Raw (and, I gather, Lightroom, with which I have minimal experience). You get some sliders like "Clarity" that effectively do a curve of a certain type, but you don't have to think about what it's doing. And that's not bad.

    Have to be careful with the analogies because not all controls work like curves. Recovery and Fill Light don't produce pure curve effects because they use masks, and Recovery uses some cross-channel calculations. Clarity has nothing to do with curves at all, it's local (regional) contrast only, another masked effect based on sharpening radius.

    I'm terrible at math so for me curves come down to a few ideas.
    1. You make the curve steeper where you want more contrast, and shallower where you want less contrast.
    2. To make it steeper in one part, you must make it shallower (lose contrast) in another part, so make sure you keep the steep parts in areas that matter and the shallow parts in areas that don't matter.
    3. You don't need to use curves if all you want is to move the black point (use Blacks instead), the white point (use Exposure instead), the midpoint (Brightness), or steepen a simple S-curve centered around the middle (Contrast). I turn to curves when I need more than what those sliders do.
  • Options
    divamumdivamum Registered Users Posts: 9,021 Major grins
    edited January 24, 2011
    Keep it coming, guys - this is great!! thumb.gifthumb.gifthumb.gif

    I hasten to add I do USE curves, but on an eyeball rather than "knowledge" basis, and it always feels a bit random. I'd like to actually know what I'm doing instead :D
  • Options
    BinaryFxBinaryFx Registered Users Posts: 707 Major grins
    edited January 24, 2011
    So far, the "master" or "composite" curve has been shown, while underlying this are the three separate channel curves (it gets even worse for CMYK, as the K channel is nothing like the CMY). Using the same (master/composite) curve shape for all three channels when adding contrast may not always be ideal, as each separate channel contains different data (ideally the curve is shaped to the individual channel content). One may get better results by custom curving each individual channel with the curve adjustment layer set to luminosity blend mode.

    Some links taken from my links page (members.ozemail.com.au/~binaryfx/links.html)

    http://www.thegoldenmean.com/technique/curves1.html
    http://www.ledet.com/margulis/PP7_Ch02_ByTheNumbers.pdf
    http://www.ledet.com/margulis/PLC_Ch02.pdf
    http://www.ledet.com/margulis/Makeready/MA21-Defanging.pdf
    http://www.eddietapp.com/PDFs/ccmethod_cs.pdf
    http://www.adobeevangelists.com/pdfs/photoshop/tipsandtricks/CorrectByNumbers.pdf

    These links are for traditional Photoshop curves, curves in raw processing software like ACR or Lightroom are different animals under the hood, however the mechanics are similar - so it is probably best to stick to say Photoshop in this discussion.


    Regards,

    Stephen Marsh

    http://binaryfx.customer.netspace.net.au/ (coming soon!)
    http://members.ozemail.com.au/~binaryfx/
    http://prepression.blogspot.com/
  • Options
    puzzledpaulpuzzledpaul Registered Users Posts: 1,621 Major grins
    edited January 25, 2011
    A complex topic and I think that it'd help if the few minor issues with the diagrams were addressed in the interests of clarity etc.

    First pic shows 202 / 212 without showing that these figs relate to a location on the graph that's under the cursor / crosshairs.
    Second pic is showing same Nos - and suggesting that this is related to the intersection of the 2 red lines - which is a totally different location from 202 / 212.

    Any set of input / output values shown should have a callout to the appropriate point on the graph, so's reader can see immediately what they refer to.

    Rather than use red for both lines, I'd be tempted to use 2 unique ways of identifying each axis (prob diff. cols, neither r,g,b) which'd make text referencing easier.

    I'm not nitpicking just for the fun of it and this isn't my job, but have found (when writing other stuff*) that small anomolies / discrepancies can make a lot of differences to a reader.

    pp

    *
    eg
  • Options
    Bend The LightBend The Light Registered Users Posts: 1,887 Major grins
    edited January 25, 2011
    Am I right in thinking that the "flat" part of the line in the third diagram (top right of curve) mean that pure white tones AND some quite close to pure white will ALL be rendered as pure white? And this is what we call "Blown Out"? A similar situation bottom left would make all black and "close to black" tones appear totally black on the output?

    Just confirming my understanding.
  • Options
    RichardRichard Administrators, Vanilla Admin Posts: 19,931 moderator
    edited January 25, 2011
    Am I right in thinking that the "flat" part of the line in the third diagram (top right of curve) mean that pure white tones AND some quite close to pure white will ALL be rendered as pure white? And this is what we call "Blown Out"? A similar situation bottom left would make all black and "close to black" tones appear totally black on the output?

    Just confirming my understanding.

    nod.gif You got it. Moving the points along the horizontal axes is another way to set the white and black points. It's the same as dragging the end points in the levels panel, except that with curves, you can then add as many additional adjustment points as you like.
  • Options
    Bend The LightBend The Light Registered Users Posts: 1,887 Major grins
    edited January 25, 2011
    Richard wrote: »
    nod.gif You got it. Moving the points along the horizontal axes is another way to set the white and black points. It's the same as dragging the end points in the levels panel, except that with curves, you can then add as many additional adjustment points as you like.

    Excellent. I understood the mathS, being a mathS teacher...just needed to clarify my actual understanding photographically.

    Cheers
  • Options
    jjbongjjbong Registered Users Posts: 244 Major grins
    edited January 25, 2011
    Excellent. I understood the mathS, being a mathS teacher...just needed to clarify my actual understanding photographically.

    Cheers

    Let me clarify further. You set a white point when the camera didn't get the full range at the high end, i.e. was a bit underexposed. This means that in the capture there just aren't any pixels that are above a certain value. The curve maps something just above this to 255, boosting the highest values in the image to maybe 245 or 250. The fact that anything higher than this gets blown out is irrelevant, as there aren't any such pixels in this image.
    John Bongiovanni
  • Options
    jjbongjjbong Registered Users Posts: 244 Major grins
    edited January 26, 2011
    A complex topic and I think that it'd help if the few minor issues with the diagrams were addressed in the interests of clarity etc.

    First pic shows 202 / 212 without showing that these figs relate to a location on the graph that's under the cursor / crosshairs.
    Second pic is showing same Nos - and suggesting that this is related to the intersection of the 2 red lines - which is a totally different location from 202 / 212.

    Any set of input / output values shown should have a callout to the appropriate point on the graph, so's reader can see immediately what they refer to.

    Rather than use red for both lines, I'd be tempted to use 2 unique ways of identifying each axis (prob diff. cols, neither r,g,b) which'd make text referencing easier.

    I'm not nitpicking just for the fun of it and this isn't my job, but have found (when writing other stuff*) that small anomolies / discrepancies can make a lot of differences to a reader.

    pp

    *
    eg

    I confess to being unhappy with my attempt to relate curves to functions in a relatively short post. Feel free to take my images and do better.
    John Bongiovanni
  • Options
    Bend The LightBend The Light Registered Users Posts: 1,887 Major grins
    edited January 26, 2011
    jjbong wrote: »
    Let me clarify further. You set a white point when the camera didn't get the full range at the high end, i.e. was a bit underexposed. This means that in the capture there just aren't any pixels that are above a certain value. The curve maps something just above this to 255, boosting the highest values in the image to maybe 245 or 250. The fact that anything higher than this gets blown out is irrelevant, as there aren't any such pixels in this image.

    Yes, I get that. Thanks again. :)
  • Options
    Jason HermannJason Hermann Registered Users Posts: 220 Major grins
    edited January 26, 2011
    If your still having issues with color correcting using Curves, check out this video tutorial I made:
    Color Correcting with Curves in PS CS5

    Best,
    Jay
  • Options
    puzzledpaulpuzzledpaul Registered Users Posts: 1,621 Major grins
    edited January 26, 2011
    << Feel free to take my images and do better. >>

    Thanks ... but it's not that attractive an offer that I feel I can't refuse :)

    Having spent many 100s of hrs writing on line tutorials (for free) for an an open source app (because there was no user manual etc), I have a reasonable understanding of what can be involved in producing this sort of material - and don't underestimate the time / effort needed.
    This situation is also different, insomuch that there's an enormous amount of info available, related to PS use.

    My comments were only made in an effort to ensure that the info was as clear and unabiguous as possible for the reader.

    pp
  • Options
    divamumdivamum Registered Users Posts: 9,021 Major grins
    edited January 26, 2011
    More fabulous info (and thanks for those very helpful article links). This is great! I hope this discussion/dialog will help others as well as me thumb.gif
  • Options
    J.G.McClainJ.G.McClain Registered Users Posts: 32 Big grins
    edited January 26, 2011
    Not to open up a 18% vs 12% vs K-factor vs Some other theory can of worms...

    But

    Anyone know what value the gray eyedropper is set to compensate to?

    After spending ALOT of time reading about it on the web, (and we all know that everything on the web is correct...) I am getting everything from 128/128/128 to 117/117/117 and from #808080 to #70707070.

    From a production stand point it really dose not matter that much for what I need/use it for, but its more of a professional curiosity.
    Jason G. McClain
    Melissa McClain Photography
    www.melissamcclainphotography.com
  • Options
    pathfinderpathfinder Super Moderators Posts: 14,698 moderator
    edited January 26, 2011
    I agree, I have read 128, 128, 128 and 135,135,135

    I suspect is really is a function of what you have set your black and white points to. Ideally it would be midway between your black and white point, but depending on what they were set to, that might not be 128,128,128.
    Pathfinder - www.pathfinder.smugmug.com

    Moderator of the Technique Forum and Finishing School on Dgrin
  • Options
    J.G.McClainJ.G.McClain Registered Users Posts: 32 Big grins
    edited January 28, 2011
    I thought that if you set a black and/or white point and then selected a gray using the dropper it moves the end point as well. Is that not what happens when you use the white/black droppers?
    Jason G. McClain
    Melissa McClain Photography
    www.melissamcclainphotography.com
  • Options
    AnthonyAnthony Registered Users Posts: 149 Major grins
    edited January 28, 2011
    pathfinder wrote: »
    I agree, I have read 128, 128, 128 and 135,135,135

    I suspect is really is a function of what you have set your black and white points to. Ideally it would be midway between your black and white point, but depending on what they were set to, that might not be 128,128,128.


    I did wonder if two things are being conflated here. Black and white point setting above/below the maximum is about clipping and shadow/highlight blocking whereas the grey point is more about colour neutrality. If this is the case - and I am more than willing to be guided here if I am wrong - then any centrally placed point between the extremes will be okay surely?

    Anthony.
  • Options
    pathfinderpathfinder Super Moderators Posts: 14,698 moderator
    edited January 28, 2011
    Anthoney , we need to understand where our white and black points come from. They come from the print, not from the monitor. At least for me. This is a point that is not well discussed or explained. Kelby and others always describe setting a black and white point your Photoshop, but not that your really want to get this from YOUR print that is the fundamental reason we are editing our images. My reference for this is Steinmuller and Gulbins "Fine Art Printing for Photographers" - an excellent book for folks wanting to really know how to wet up their computer and their printer.

    As you pointed out, a neutral color is any pixel when each of the three channels ( in RGB ) are the same whether 2,2,2, or 237,237,237. BUT these pixels are not grey, they are a black and a white.

    Grey should be ~ midway between 0,0,0 and 255,255,255 which is 255/2= 127.5 or 128 in the digital world since their can be no 127.5.

    The issue is that your printer will not print so that you can look at the print and see a difference in tonality between 0,0,0 and 3,33, or 4,4,4 and some times even 8,8,8 - It all depends on your printer, paper and inkset. The same is true for the white point - whether 249,249,249 or 252,252,253 or 255,255,255 To determine your black point and your white point for YOUR pinter, paper, and inkset - print a posterized graduated scale from white to black on paper and determine the actual darkest spot on the scale nearest the center that you can see an actual perceptible difference and that will be your black point. Look at the lightest steps and see the brightest, from the center, that you can no longer see any difference with less ink, and that will be your white point.

    So if your printer's black point is 8,8,8 and the white point is 252,252,252 then 252-8 = 244 244/2 = 122 your actual neutral grey point for that printer, paper, and inkset.

    At least this is my understanding of this issue.
    Pathfinder - www.pathfinder.smugmug.com

    Moderator of the Technique Forum and Finishing School on Dgrin
  • Options
    AnthonyAnthony Registered Users Posts: 149 Major grins
    edited January 28, 2011
    pathfinder wrote: »
    Anthoney , we need to understand where our white and black points come from. They come from the print, not from the monitor. ...

    [..]


    Thanks for the explanation, I found it helpful. I checked on Amazon [UK] regarding the book you mention and initially could only find the German version - and my German is nowhere good enough for that (or the c.$50 asking price)! However, a round trip to Amazon USA to collect some more details and back to Amazon UK pinned it down. I assume the 2nd edition - 2008 is the one you have?

    Anthony.
  • Options
    J.G.McClainJ.G.McClain Registered Users Posts: 32 Big grins
    edited January 28, 2011
    Looking up the book, thanks for the reference. Not to throw a monkey wrench into it, for a photographer that dose not print locally, but uses a printing shop. Would a work flow be to send a posterized graduated scale to the printer, then set to that? or is it a mute point if you are sending it to a pro shop that does collection prior to printing anyhow?
    Jason G. McClain
    Melissa McClain Photography
    www.melissamcclainphotography.com
  • Options
    pathfinderpathfinder Super Moderators Posts: 14,698 moderator
    edited January 28, 2011
    Anthony wrote: »
    Thanks for the explanation, I found it helpful. I checked on Amazon [UK] regarding the book you mention and initially could only find the German version - and my German is nowhere good enough for that (or the c.$50 asking price)! However, a round trip to Amazon USA to collect some more details and back to Amazon UK pinned it down. I assume the 2nd edition - 2008 is the one you have?

    Anthony.

    Actually my copy is the first edition 2007, and I assure you it is in English. Published by Rocky Nook of course.

    The authors are German, and I know the book is printed in German as well, but like you, I prefer my copy in the King's English.
    Pathfinder - www.pathfinder.smugmug.com

    Moderator of the Technique Forum and Finishing School on Dgrin
  • Options
    pathfinderpathfinder Super Moderators Posts: 14,698 moderator
    edited January 28, 2011
    Looking up the book, thanks for the reference. Not to throw a monkey wrench into it, for a photographer that dose not print locally, but uses a printing shop. Would a work flow be to send a posterized graduated scale to the printer, then set to that? or is it a mute point if you are sending it to a pro shop that does collection prior to printing anyhow?

    Melissa, I am not sure I am the person to answer this specific question, since it depends on what the printer is going to do with your file prior to printing, and I have no way of knowing that.

    Smugmug does provide you with a test print and file, so that you can see the image file on your screen, and compare it to the actual print ( on paper ) you receive from smugmug as well. The image file is here - http://www.smugmug.com/help/calibration-1400.mg

    There are some nice grey step scale images here -- www.hutchcolor.com/Images_and_targets.html
    Pathfinder - www.pathfinder.smugmug.com

    Moderator of the Technique Forum and Finishing School on Dgrin
  • Options
    pathfinderpathfinder Super Moderators Posts: 14,698 moderator
    edited January 28, 2011
    You can make your own grey step scale in Photoshop by creating a black to white gradient, and then posterizing it with the desired number of steps you need.
    Pathfinder - www.pathfinder.smugmug.com

    Moderator of the Technique Forum and Finishing School on Dgrin
  • Options
    J.G.McClainJ.G.McClain Registered Users Posts: 32 Big grins
    edited January 28, 2011
    Pathfinder,

    Thanks for the info, and all the feedback. This is the type of things that I love about this form, experance and information sharing is a good thing.

    Its Jason by the way :) Melissa's Husband.

    Have a good weekend.

    ~Jason
    Jason G. McClain
    Melissa McClain Photography
    www.melissamcclainphotography.com
  • Options
    pathfinderpathfinder Super Moderators Posts: 14,698 moderator
    edited January 29, 2011
    Sorry for the mis-naming, Jason.
    Pathfinder - www.pathfinder.smugmug.com

    Moderator of the Technique Forum and Finishing School on Dgrin
  • Options
    Jason HermannJason Hermann Registered Users Posts: 220 Major grins
    edited February 1, 2011
    I really don't think the neutral gray value difference of only a few #'s really matters. It is curious why both #'s are psoted on the web though ;)

    Jay
  • Options
    pathfinderpathfinder Super Moderators Posts: 14,698 moderator
    edited February 1, 2011
    I don't think it matters much either, Jay. A slightly brighter neutral grey will lighten the appearance of one's prints just a a bit, and if you know your display location lighting is less than brilliant, might help them a bit.
    Pathfinder - www.pathfinder.smugmug.com

    Moderator of the Technique Forum and Finishing School on Dgrin
Sign In or Register to comment.