avcodec: use context->channels in audio encoding
avcodec: use context->channels in audio encoding

Input and output channel count should be anyway the same and it's
hopefully littlebit clearer than fmt_in and fmt_out mixups.
(cherry picked from commit 4f11edd7bcacea1fa0b44161b76091e98aeed7a2)

Signed-off-by: Ilkka Ollakka <88b345e2e0969920adc1eaa21d1a29b223865bcf@videolan.org>

vlc-mirror/vlc-2.1,vlc-mirror/vlc-2.1,vlc-mirror/vlc-2.1,jomanmuk/vlc-2.1,vlc-mirror/vlc-2.1,vlc-mirror/vlc-2.1,vlc-mirror/vlc-2.1,jomanmuk/vlc-2.1,jomanmuk/vlc-2.1,vlc-mirror/vlc-2.1,jomanmuk/vlc-2.1,jomanmuk/vlc-2.1,jomanmuk/vlc-2.1,jomanmuk/vlc-2.1