Integrated channel mapping routine into player_main and supporting functions.