Browse code

ra144dec: set channel layout

Justin Ruggles authored on 2012/10/23 07:57:39
Showing 1 changed files
... ...
@@ -22,6 +22,7 @@
22 22
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
23 23
  */
24 24
 
25
+#include "libavutil/audioconvert.h"
25 26
 #include "libavutil/intmath.h"
26 27
 #include "avcodec.h"
27 28
 #include "get_bits.h"
... ...
@@ -37,7 +38,9 @@ static av_cold int ra144_decode_init(AVCodecContext * avctx)
37 37
     ractx->lpc_coef[0] = ractx->lpc_tables[0];
38 38
     ractx->lpc_coef[1] = ractx->lpc_tables[1];
39 39
 
40
-    avctx->sample_fmt = AV_SAMPLE_FMT_S16;
40
+    avctx->channels       = 1;
41
+    avctx->channel_layout = AV_CH_LAYOUT_MONO;
42
+    avctx->sample_fmt     = AV_SAMPLE_FMT_S16;
41 43
 
42 44
     avcodec_get_frame_defaults(&ractx->frame);
43 45
     avctx->coded_frame = &ractx->frame;