Remove code duplication in sws_rgb2rgb_init.