Flip rgb correctly