CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    Aug 2003
    Location
    Canada
    Posts
    164

    Photoshop Adjust Brightness algorithm

    What general algorithm do they use? When you brighten a dark image, it increases the luminosity of dark pixels more than the bright ones. The bright pixels are not allowed to reach or surpass full white.

    Any ideas?

  2. #2
    Join Date
    Aug 2003
    Location
    Canada
    Posts
    164

  3. #3
    Join Date
    Aug 2003
    Location
    Canada
    Posts
    164

    Re: Photoshop Adjust Brightness algorithm

    All it does is shift the luminosity histogram over.

    The amount -100..0..+100 is the amount of the shift (where the historgam exists from 0..255). So, it has nothing to do with a %. It's just -100..100 of 255.

  4. #4
    Join Date
    Aug 2003
    Location
    Canada
    Posts
    164

    Re: Photoshop Adjust Brightness algorithm

    It's even more simple than that. It just adds x = -100..100 to R, G, and B, and bounds them to 0..255, with no regard to the fact the hue changes.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured