You've got a line there that says brightnessFactor = a whole bunch of integer math. Integer math is only going to give inter gets, it will never give you 0.82 or any other decimal number.Make those constants floats like 1.0 and 2.0 instead of just 1 and 2 and see what happens.
Please enter a valid email to subscribe
We need to confirm your email address.
To complete the subscription, please click the link in the
email we just sent you.
Thank you for subscribing!
via Egeo 16