diff options
author | Justin Ruggles <justin.ruggles@gmail.com> | 2012-04-07 14:00:04 -0400 |
---|---|---|
committer | Justin Ruggles <justin.ruggles@gmail.com> | 2012-11-12 10:33:19 -0500 |
commit | f6c3adde41921082964055193efbcf58195bf457 (patch) | |
tree | 8575da9901027f2c2834785ac4e5c06f0f150d73 /libavformat/gxf.c | |
parent | d4a105ae5c1b0c6118872c8b729c3ac751281ed0 (diff) | |
download | ffmpeg-f6c3adde41921082964055193efbcf58195bf457.tar.gz |
gxfdec: set channel layout when applicable
Diffstat (limited to 'libavformat/gxf.c')
-rw-r--r-- | libavformat/gxf.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libavformat/gxf.c b/libavformat/gxf.c index 2593c0642b..6feb3c30dc 100644 --- a/libavformat/gxf.c +++ b/libavformat/gxf.c @@ -19,6 +19,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ +#include "libavutil/channel_layout.h" #include "libavutil/common.h" #include "avformat.h" #include "internal.h" @@ -119,6 +120,7 @@ static int get_sindex(AVFormatContext *s, int id, int format) { st->codec->codec_type = AVMEDIA_TYPE_AUDIO; st->codec->codec_id = AV_CODEC_ID_PCM_S24LE; st->codec->channels = 1; + st->codec->channel_layout = AV_CH_LAYOUT_MONO; st->codec->sample_rate = 48000; st->codec->bit_rate = 3 * 1 * 48000 * 8; st->codec->block_align = 3 * 1; @@ -128,6 +130,7 @@ static int get_sindex(AVFormatContext *s, int id, int format) { st->codec->codec_type = AVMEDIA_TYPE_AUDIO; st->codec->codec_id = AV_CODEC_ID_PCM_S16LE; st->codec->channels = 1; + st->codec->channel_layout = AV_CH_LAYOUT_MONO; st->codec->sample_rate = 48000; st->codec->bit_rate = 2 * 1 * 48000 * 8; st->codec->block_align = 2 * 1; @@ -137,6 +140,7 @@ static int get_sindex(AVFormatContext *s, int id, int format) { st->codec->codec_type = AVMEDIA_TYPE_AUDIO; st->codec->codec_id = AV_CODEC_ID_AC3; st->codec->channels = 2; + st->codec->channel_layout = AV_CH_LAYOUT_STEREO; st->codec->sample_rate = 48000; break; // timecode tracks: |