We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I did some tests and MedianCut tends to make images darker because all colors besides white are with their last 3 bits set to '0'.
MedianCut
https://github.com/imagej/imagej1/blob/faaa7e0b29e91afff5cba11b8c0e700d9e976ea4/ij/process/MedianCut.java#L253-L254
The following replacement does a much better job:
// adjust values, i.e. we had the last 3 bits cut off: [0, 248] --> [0, 255] r = (255 * r) / 248; g = (255 * g) / 248; b = (255 * b) / 248;
This also resets white to its original color.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I did some tests and
MedianCut
tends to make images darker because all colors besides white are with their last 3 bits set to '0'.The following replacement does a much better job:
This also resets white to its original color.
The text was updated successfully, but these errors were encountered: