From mplayer-dev-eng Sat Apr 11 13:27:29 2009 From: Andrew de Quincey Date: Sat, 11 Apr 2009 13:27:29 +0000 To: mplayer-dev-eng Subject: [MPlayer-dev-eng] [Patch] Fix eac3 channel ordering Message-Id: <20090411142729.548366wd2zq97cao () lidskialf ! net> X-MARC-Message: https://marc.info/?l=mplayer-dev-eng&m=123947384816969 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--=_65dymtroh5og" This message is in MIME format. --=_65dymtroh5og Content-Type: text/plain; charset=UTF-8; DelSp="Yes"; format="flowed" Content-Disposition: inline Content-Transfer-Encoding: 7bit Hi, this is a resubmission of my original patch with the libmpdemux code removed; this now *only* fixes the EAC3 channel ordering. Basically, there's no special handling for the "eac3" codec in libmpcodecs/ad_ffmpeg.c, so it uses the default, which is wrong for that codec. --=_65dymtroh5og Content-Type: text/x-patch; charset=UTF-8; name="fix-eac-channel-ordering.patch" Content-Disposition: attachment; filename="fix-eac-channel-ordering.patch" Content-Transfer-Encoding: 7bit Index: libmpcodecs/ad_ffmpeg.c =================================================================== --- libmpcodecs/ad_ffmpeg.c (revision 29169) +++ libmpcodecs/ad_ffmpeg.c (working copy) @@ -175,7 +175,8 @@ if (((AVCodecContext *)sh_audio->context)->channels >= 5) { int src_ch_layout = AF_CHANNEL_LAYOUT_MPLAYER_DEFAULT; const char *codec=((AVCodecContext*)sh_audio->context)->codec->name; - if (!strcasecmp(codec, "ac3")) + if (!strcasecmp(codec, "ac3") + || !strcasecmp(codec, "eac3")) src_ch_layout = AF_CHANNEL_LAYOUT_LAVC_AC3_DEFAULT; else if (!strcasecmp(codec, "dca")) src_ch_layout = AF_CHANNEL_LAYOUT_LAVC_DCA_DEFAULT; --=_65dymtroh5og Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ MPlayer-dev-eng mailing list MPlayer-dev-eng@mplayerhq.hu https://lists.mplayerhq.hu/mailman/listinfo/mplayer-dev-eng --=_65dymtroh5og--