501 - not implemented
501 - not implemented

Reputation: 2698

How to automatic adjust color and contrast

in my project i want to implement a modul which add or remove contrast to a given picture automatically. My problem is, to find out how much contrast i can add or remove. I know about photoshops auto-contrast/auto-color function. Can someone explain me how it works or a theory/paper/idea how to implement this?

I know, there is a histogram-equalization feature. But that's not the feature i'm seeking for.

For example i want to choose one of this three gradiant-curves,which match with the image.

Image Hosted by ImageShack.us Image Hosted by ImageShack.us Image Hosted by ImageShack.us

greetings

Upvotes: 10

Views: 18101

Answers (2)

alex555
alex555

Reputation: 1786

Just as an alternative to the Adi Shavit's answer there is also a nonlinear algorithm for the image contrast enhancement described in a paper http://www.asp.eurasipjournals.com/content/pdf/1687-6180-2014-70.pdf. Someone may be interested in it.

Upvotes: 4

Adi Shavit
Adi Shavit

Reputation: 17295

A simple linear way of performing "auto-contrast" is to linearly stretch and offset the image intensities. The idea is to find the stretch (contrast) and offset (intensity) correction parameters such that in the corrected image the 5th percentile will be mapped to 0, and the 95th percentile will be mapped to 255.

Check out my answer here for more details.

Upvotes: 12

Related Questions