# Improvement over gamma correction for brightening images?

I'd like to brighten one of my own images for printing purposes, using a program I made.

When I use the formula: pixelBrightness^0.6 to brighten an image (0.6 being an example, and where pixelBrightness is in the normalized range 0..1), I find the very dark colours (black or near black) contrast too much with the somewhat dark colours. This is standard gamma correction.

Mathematically this makes sense, because the (b^0.6) curve 'hugs' the left wall for a bit on the graph, and only eases out half way through. See here to show what I mean. However, unfortunately, this makes the near blacks too 'contrasty'. I want the very beginning of the curve to be more like 20-30 degrees off from pure vertical.

Is there a simple formula (e.g: like pixelBrightness^0.6) which is better than gamma correction for my purposes? After the two points (start (0,0) and end (1,1)) have been defined, I preferably want a single degree of freedom to determine how 'curvy' (for want of a better word please?) the curve is (i.e.: how dissimilar to a line it is). So bezier curves (with their two degrees of freedom) are possibly out.

• You could try $y=x/(a(1-x)+x)$ with $a>0$, which is the one-parameter family of rational functions through $(0,0)$ and $(1,1)$. Related: math.stackexchange.com/q/297768/856
– user856
Feb 2, 2015 at 17:19
• Wonderful and so simple! Please add this as an answer (and any others you might think of). I wonder if there's any theoretical basis for this improving over the standard gamma correction technique for many purposes. Feb 2, 2015 at 17:38

Another option: $$y = 2hx + (1-2h)x^2$$ This is a quadratic Bezier curve with control "values" $0,h,1$. I suggest this only because you mentioned Bezier curves. Rahul's function gives you more flexibility.