svoid test_BWImage() { assertEqualsVerbose(127.0, BWImage(2, 2, 0.5f).averageBrightness()); assertEqualsVerbose(63.0, BWImage(2, 2, 0.25f).averageBrightness()); assertEqualsVerbose(191.25, BWImage(2, 2, new float[] {0, 1, 1, 1}).averageBrightness()); }