Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Color curve operation with OpenCV: Increase contrast

Hi

With the Gimp image manipulation program, I frequently increase contrast by using the color curve tool. From this:

image description

to this:

image description(/upfiles/1387210577269045.png)

There is a small tutorial that talks about increasing contrast here: http://docs.opencv.org/doc/tutorials/core/basic_linear_transform/basic_linear_transform.html

Therefore, I assume this operation would give the desired effect:

image.convertTo(alpha: 1.3, beta: -20)

I would have to calculate the exact alpha and beta values in order to exactly represent the above color curve. Maybe anybody can comment on these assumptions?

Thank you very much.

Color curve operation with OpenCV: Increase contrast

Hi

With the Gimp image manipulation program, I frequently increase contrast by using the color curve tool. From this:

image description

to this:

image description(/upfiles/1387210577269045.png)

There is a small tutorial that talks about increasing contrast here: http://docs.opencv.org/doc/tutorials/core/basic_linear_transform/basic_linear_transform.html

Therefore, I assume this operation would give the desired effect:

image.convertTo(alpha: 1.3, beta: -20)

I would have to calculate the exact alpha and beta values in order to exactly represent the above color curve. Maybe anybody can comment on these assumptions?

Thank you very much.

Color curve operation with OpenCV: Increase contrast

Hi

With the Gimp image manipulation program, I frequently increase contrast by using the color curve tool. From this:

image description

to this:

image description

There is a small tutorial that talks about increasing contrast here: http://docs.opencv.org/doc/tutorials/core/basic_linear_transform/basic_linear_transform.html

Therefore, I assume this operation would give the desired effect:

image.convertTo(alpha: 1.3, beta: -20)

I would have to calculate the exact alpha and beta values in order to exactly represent the above color curve. Maybe anybody can comment on these assumptions?assumptions or has suggestions?

Thank you very much.