Updated brightness function, xinit