I made a program to take a picture of myself and text it to me whenever I enter in the wrong code, but the picture is very hard to see without turning the screen on my phone. I think the contrast is too low, but I have no clue on how to do this. My code saves the picture to a png file and sends that to me, so it has to be a file (and not to a JFrame like how I saw in everything I found online)
Asked
Active
Viewed 310 times
0
-
1http://stackoverflow.com/questions/3433275/adjust-brightness-and-contrast-of-bufferedimage-in-java – Murat Karagöz Feb 01 '15 at 15:33
1 Answers
1
You could use histogram equalization to increase the contrast/visibility. See the section of Examples - Full sized image for a grayscale example.
There are already implementations available, so you don't have do it yourself. One of which I found here, which appears to preserve the color: HistogramEqualizer.java by a Student of Tunghai University.

Lumiukko
- 437
- 3
- 8