1 /*****************************************************************************
2 * araw.c: Pseudo audio decoder; for raw pcm data
3 *****************************************************************************
4 * Copyright (C) 2001, 2003 VLC authors and VideoLAN
6 * Authors: Laurent Aimar <fenrir@via.ecp.fr>
8 * This program is free software; you can redistribute it and/or modify it
9 * under the terms of the GNU Lesser General Public License as published by
10 * the Free Software Foundation; either version 2.1 of the License, or
11 * (at your option) any later version.
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU Lesser General Public License for more details.
18 * You should have received a copy of the GNU Lesser General Public License
19 * along with this program; if not, write to the Free Software Foundation,
20 * Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
21 *****************************************************************************/
23 /*****************************************************************************
25 *****************************************************************************/
33 #include <vlc_common.h>
34 #include <vlc_plugin.h>
35 #include <vlc_codec.h>
38 /*****************************************************************************
40 *****************************************************************************/
41 static int DecoderOpen ( vlc_object_t
* );
44 static int EncoderOpen ( vlc_object_t
* );
48 /* audio decoder module */
49 set_description( N_("Raw/Log Audio decoder") )
50 set_capability( "audio decoder", 100 )
51 set_category( CAT_INPUT
)
52 set_subcategory( SUBCAT_INPUT_ACODEC
)
53 set_callback( DecoderOpen
)
56 /* audio encoder submodule */
58 set_description( N_("Raw audio encoder") )
59 set_capability( "encoder", 150 )
60 set_callback( EncoderOpen
)
64 /*****************************************************************************
66 *****************************************************************************/
67 static int DecodeBlock( decoder_t
*, block_t
* );
68 static void Flush( decoder_t
* );
72 void (*decode
) (void *, const uint8_t *, unsigned);
77 static void S8Decode( void *, const uint8_t *, unsigned );
78 static void U16BDecode( void *, const uint8_t *, unsigned );
79 static void U16LDecode( void *, const uint8_t *, unsigned );
80 static void S16IDecode( void *, const uint8_t *, unsigned );
81 static void S20BDecode( void *, const uint8_t *, unsigned );
82 static void U24BDecode( void *, const uint8_t *, unsigned );
83 static void U24LDecode( void *, const uint8_t *, unsigned );
84 static void S24BDecode( void *, const uint8_t *, unsigned );
85 static void S24LDecode( void *, const uint8_t *, unsigned );
86 static void S24B32Decode( void *, const uint8_t *, unsigned );
87 static void S24L32Decode( void *, const uint8_t *, unsigned );
88 static void U32BDecode( void *, const uint8_t *, unsigned );
89 static void U32LDecode( void *, const uint8_t *, unsigned );
90 static void S32IDecode( void *, const uint8_t *, unsigned );
91 static void F32NDecode( void *, const uint8_t *, unsigned );
92 static void F32IDecode( void *, const uint8_t *, unsigned );
93 static void F64NDecode( void *, const uint8_t *, unsigned );
94 static void F64IDecode( void *, const uint8_t *, unsigned );
95 static void DAT12Decode( void *, const uint8_t *, unsigned );
97 /*****************************************************************************
98 * DecoderOpen: probe the decoder and return score
99 *****************************************************************************/
100 static int DecoderOpen( vlc_object_t
*p_this
)
102 decoder_t
*p_dec
= (decoder_t
*)p_this
;
103 vlc_fourcc_t format
= p_dec
->fmt_in
.i_codec
;
105 switch( p_dec
->fmt_in
.i_codec
)
107 case VLC_FOURCC('a','r','a','w'):
108 case VLC_FOURCC('a','f','l','t'):
109 /* _signed_ big endian samples (mov) */
110 case VLC_FOURCC('t','w','o','s'):
111 /* _signed_ little endian samples (mov) */
112 case VLC_FOURCC('s','o','w','t'):
114 vlc_fourcc_GetCodecAudio( p_dec
->fmt_in
.i_codec
,
115 p_dec
->fmt_in
.audio
.i_bitspersample
);
118 msg_Err( p_dec
, "bad parameters(bits/sample)" );
124 void (*decode
) (void *, const uint8_t *, unsigned) = NULL
;
129 #ifdef WORDS_BIGENDIAN
134 format
= VLC_CODEC_FL64
;
142 #ifdef WORDS_BIGENDIAN
147 format
= VLC_CODEC_FL32
;
156 format
= VLC_CODEC_S32N
;
161 format
= VLC_CODEC_S32N
;
166 format
= VLC_CODEC_S32N
;
172 case VLC_CODEC_S24B32
:
173 format
= VLC_CODEC_S32N
;
174 decode
= S24B32Decode
;
177 case VLC_CODEC_S24L32
:
178 format
= VLC_CODEC_S32N
;
179 decode
= S24L32Decode
;
183 format
= VLC_CODEC_S32N
;
188 format
= VLC_CODEC_S32N
;
193 format
= VLC_CODEC_S32N
;
198 format
= VLC_CODEC_S32N
;
203 format
= VLC_CODEC_S32N
;
208 format
= VLC_CODEC_S16N
;
213 format
= VLC_CODEC_S16N
;
218 format
= VLC_CODEC_S16N
;
224 case VLC_CODEC_DAT12
:
225 format
= VLC_CODEC_S16N
;
226 decode
= DAT12Decode
;
231 format
= VLC_CODEC_U8
;
240 if( p_dec
->fmt_in
.audio
.i_channels
== 0 ||
241 p_dec
->fmt_in
.audio
.i_channels
> INPUT_CHAN_MAX
)
243 msg_Err( p_dec
, "bad channels count (1-%i): %i",
244 AOUT_CHAN_MAX
, p_dec
->fmt_in
.audio
.i_channels
);
248 if( p_dec
->fmt_in
.audio
.i_rate
== 0 || p_dec
->fmt_in
.audio
.i_rate
> 384000 )
250 msg_Err( p_dec
, "bad samplerate: %d Hz", p_dec
->fmt_in
.audio
.i_rate
);
254 msg_Dbg( p_dec
, "samplerate:%dHz channels:%d bits/sample:%d",
255 p_dec
->fmt_in
.audio
.i_rate
, p_dec
->fmt_in
.audio
.i_channels
,
256 p_dec
->fmt_in
.audio
.i_bitspersample
);
258 /* Allocate the memory needed to store the decoder's structure */
259 decoder_sys_t
*p_sys
= vlc_obj_malloc(p_this
, sizeof(*p_sys
));
260 if( unlikely(p_sys
== NULL
) )
263 /* Set output properties */
264 p_dec
->fmt_out
.i_codec
= format
;
265 p_dec
->fmt_out
.audio
.channel_type
= p_dec
->fmt_in
.audio
.channel_type
;
266 p_dec
->fmt_out
.audio
.i_format
= format
;
267 p_dec
->fmt_out
.audio
.i_rate
= p_dec
->fmt_in
.audio
.i_rate
;
268 if( p_dec
->fmt_in
.audio
.i_channels
< ARRAY_SIZE(vlc_chan_maps
) )
270 if( p_dec
->fmt_in
.audio
.i_physical_channels
)
271 p_dec
->fmt_out
.audio
.i_physical_channels
=
272 p_dec
->fmt_in
.audio
.i_physical_channels
;
274 p_dec
->fmt_out
.audio
.i_physical_channels
=
275 vlc_chan_maps
[p_dec
->fmt_in
.audio
.i_channels
];
279 /* Unknown channel map, let the aout/filters decide what to do */
280 p_dec
->fmt_out
.audio
.i_channels
= p_dec
->fmt_in
.audio
.i_channels
;
281 p_dec
->fmt_out
.audio
.i_physical_channels
= 0;
283 aout_FormatPrepare( &p_dec
->fmt_out
.audio
);
285 p_sys
->decode
= decode
;
286 p_sys
->framebits
= bits
* p_dec
->fmt_out
.audio
.i_channels
;
287 assert( p_sys
->framebits
);
289 date_Init( &p_sys
->end_date
, p_dec
->fmt_out
.audio
.i_rate
, 1 );
291 p_dec
->pf_decode
= DecodeBlock
;
292 p_dec
->pf_flush
= Flush
;
293 p_dec
->p_sys
= p_sys
;
298 /*****************************************************************************
300 *****************************************************************************/
301 static void Flush( decoder_t
*p_dec
)
303 decoder_sys_t
*p_sys
= p_dec
->p_sys
;
305 date_Set( &p_sys
->end_date
, VLC_TICK_INVALID
);
308 /****************************************************************************
309 * DecodeBlock: the whole thing
310 ****************************************************************************
311 * This function must be fed with whole samples (see nBlockAlign).
312 ****************************************************************************/
313 static int DecodeBlock( decoder_t
*p_dec
, block_t
*p_block
)
315 decoder_sys_t
*p_sys
= p_dec
->p_sys
;
316 if( p_block
== NULL
) /* No Drain */
317 return VLCDEC_SUCCESS
;
319 if( p_block
->i_flags
& (BLOCK_FLAG_CORRUPTED
|BLOCK_FLAG_DISCONTINUITY
) )
322 if( p_block
->i_flags
& BLOCK_FLAG_CORRUPTED
)
326 if( p_block
->i_pts
!= VLC_TICK_INVALID
&&
327 p_block
->i_pts
!= date_Get( &p_sys
->end_date
) )
329 date_Set( &p_sys
->end_date
, p_block
->i_pts
);
331 else if( date_Get( &p_sys
->end_date
) == VLC_TICK_INVALID
)
332 /* We've just started the stream, wait for the first PTS. */
335 unsigned samples
= (8 * p_block
->i_buffer
) / p_sys
->framebits
;
339 if( p_sys
->decode
!= NULL
)
341 if( decoder_UpdateAudioFormat( p_dec
) )
343 block_t
*p_out
= decoder_NewAudioBuffer( p_dec
, samples
);
347 p_sys
->decode( p_out
->p_buffer
, p_block
->p_buffer
,
348 samples
* p_dec
->fmt_in
.audio
.i_channels
);
349 block_Release( p_block
);
354 if( decoder_UpdateAudioFormat( p_dec
) )
356 p_block
->i_nb_samples
= samples
;
357 p_block
->i_buffer
= samples
* (p_sys
->framebits
/ 8);
360 p_block
->i_pts
= date_Get( &p_sys
->end_date
);
361 p_block
->i_length
= date_Increment( &p_sys
->end_date
, samples
)
363 decoder_QueueAudio( p_dec
, p_block
);
364 return VLCDEC_SUCCESS
;
366 block_Release( p_block
);
367 return VLCDEC_SUCCESS
;
370 static void S8Decode( void *outp
, const uint8_t *in
, unsigned samples
)
374 for( size_t i
= 0; i
< samples
; i
++ )
375 out
[i
] = in
[i
] ^ 0x80;
378 static void U16BDecode( void *outp
, const uint8_t *in
, unsigned samples
)
380 uint16_t *out
= outp
;
382 for( size_t i
= 0; i
< samples
; i
++ )
384 *(out
++) = GetWBE( in
) - 0x8000;
389 static void U16LDecode( void *outp
, const uint8_t *in
, unsigned samples
)
391 uint16_t *out
= outp
;
393 for( size_t i
= 0; i
< samples
; i
++ )
395 *(out
++) = GetWLE( in
) - 0x8000;
400 static void S16IDecode( void *out
, const uint8_t *in
, unsigned samples
)
402 swab( in
, out
, samples
* 2 );
405 static void S20BDecode( void *outp
, const uint8_t *in
, unsigned samples
)
409 while( samples
>= 2 )
411 uint32_t dw
= U32_AT(in
);
413 *(out
++) = dw
& ~0xFFF;
414 *(out
++) = (dw
<< 20) | (*in
<< 12);
419 /* No U32_AT() for the last odd sample: avoid off-by-one overflow! */
421 *(out
++) = (U16_AT(in
) << 16) | ((in
[2] & 0xF0) << 8);
424 static void U24BDecode( void *outp
, const uint8_t *in
, unsigned samples
)
426 uint32_t *out
= outp
;
428 for( size_t i
= 0; i
< samples
; i
++ )
430 uint32_t s
= ((in
[0] << 24) | (in
[1] << 16) | (in
[2] << 8)) - 0x80000000;
436 static void U24LDecode( void *outp
, const uint8_t *in
, unsigned samples
)
438 uint32_t *out
= outp
;
440 for( size_t i
= 0; i
< samples
; i
++ )
442 uint32_t s
= ((in
[2] << 24) | (in
[1] << 16) | (in
[0] << 8)) - 0x80000000;
448 static void S24BDecode( void *outp
, const uint8_t *in
, unsigned samples
)
450 uint32_t *out
= outp
;
452 for( size_t i
= 0; i
< samples
; i
++ )
454 uint32_t s
= ((in
[0] << 24) | (in
[1] << 16) | (in
[2] << 8));
460 static void S24LDecode( void *outp
, const uint8_t *in
, unsigned samples
)
462 uint32_t *out
= outp
;
464 for( size_t i
= 0; i
< samples
; i
++ )
466 uint32_t s
= ((in
[2] << 24) | (in
[1] << 16) | (in
[0] << 8));
472 static void S24B32Decode( void *outp
, const uint8_t *in
, unsigned samples
)
474 uint32_t *out
= outp
;
476 for( size_t i
= 0; i
< samples
; i
++ )
478 *(out
++) = GetDWBE( in
) << 8;
483 static void S24L32Decode( void *outp
, const uint8_t *in
, unsigned samples
)
485 uint32_t *out
= outp
;
487 for( size_t i
= 0; i
< samples
; i
++ )
489 *(out
++) = GetDWLE( in
) << 8;
494 static void U32BDecode( void *outp
, const uint8_t *in
, unsigned samples
)
496 uint32_t *out
= outp
;
498 for( size_t i
= 0; i
< samples
; i
++ )
500 *(out
++) = GetDWBE( in
) - 0x80000000;
505 static void U32LDecode( void *outp
, const uint8_t *in
, unsigned samples
)
507 uint32_t *out
= outp
;
509 for( size_t i
= 0; i
< samples
; i
++ )
511 *(out
++) = GetDWLE( in
) - 0x80000000;
516 static void S32IDecode( void *outp
, const uint8_t *in
, unsigned samples
)
520 for( size_t i
= 0; i
< samples
; i
++ )
522 #ifdef WORDS_BIGENDIAN
523 *(out
++) = GetDWLE( in
);
525 *(out
++) = GetDWBE( in
);
531 static void F32NDecode( void *outp
, const uint8_t *in
, unsigned samples
)
535 for( size_t i
= 0; i
< samples
; i
++ )
537 memcpy( out
, in
, sizeof(float) );
538 if( unlikely(!isfinite(*out
)) )
545 static void F32IDecode( void *outp
, const uint8_t *in
, unsigned samples
)
549 for( size_t i
= 0; i
< samples
; i
++ )
551 union { float f
; uint32_t u
; } s
;
553 #ifdef WORDS_BIGENDIAN
558 if( unlikely(!isfinite(s
.f
)) )
565 static void F64NDecode( void *outp
, const uint8_t *in
, unsigned samples
)
569 for( size_t i
= 0; i
< samples
; i
++ )
571 memcpy( out
, in
, sizeof(double) );
572 if( unlikely(!isfinite( *out
)) )
575 in
+= sizeof(double);
579 static void F64IDecode( void *outp
, const uint8_t *in
, unsigned samples
)
583 for( size_t i
= 0; i
< samples
; i
++ )
585 union { double d
; uint64_t u
; } s
;
587 #ifdef WORDS_BIGENDIAN
592 if( unlikely(!isfinite( s
.d
)) )
599 static int_fast16_t dat12tos16( uint_fast16_t y
)
601 static const int16_t diff
[16] = {
602 0x0000, 0x0000, 0x0100, 0x0200, 0x0300, 0x0400, 0x0500, 0x0600,
603 0x0A00, 0x0B00, 0x0C00, 0x0D00, 0x0E00, 0x0F00, 0x1000, 0x1000,
605 static const uint8_t shift
[16] = {
606 0, 0, 1, 2, 3, 4, 5, 6, 6, 5, 4, 3, 2, 1, 0, 0
612 return ((int)y
- diff
[d
]) << shift
[d
];
615 static void DAT12Decode( void *outp
, const uint8_t *in
, unsigned samples
)
619 while( samples
>= 2 )
621 *(out
++) = dat12tos16(U16_AT(in
) >> 4);
622 *(out
++) = dat12tos16(U16_AT(in
+ 1) & ~0xF000);
628 *(out
++) = dat12tos16(U16_AT(in
) >> 4);
632 /* NOTE: Output buffers are always aligned since they are allocated by the araw plugin.
633 * Contrary to the decoder, the encoder can also assume that input buffers are aligned,
634 * since decoded audio blocks must always be aligned. */
636 static void U16IEncode( void *outp
, const uint8_t *inp
, unsigned samples
)
638 const uint16_t *in
= (const uint16_t *)inp
;
639 uint16_t *out
= outp
;
641 for( size_t i
= 0; i
< samples
; i
++ )
642 *(out
++) = vlc_bswap16( *(in
++) + 0x8000 );
645 static void U16NEncode( void *outp
, const uint8_t *inp
, unsigned samples
)
647 const uint16_t *in
= (const uint16_t *)inp
;
648 uint16_t *out
= outp
;
650 for( size_t i
= 0; i
< samples
; i
++ )
651 *(out
++) = *(in
++) + 0x8000;
654 static void U24BEncode( void *outp
, const uint8_t *inp
, unsigned samples
)
656 const uint32_t *in
= (const uint32_t *)inp
;
659 for( size_t i
= 0; i
< samples
; i
++ )
661 uint32_t s
= *(in
++);
662 *(out
++) = (s
>> 24) + 0x80;
663 *(out
++) = (s
>> 16);
668 static void U24LEncode( void *outp
, const uint8_t *inp
, unsigned samples
)
670 const uint32_t *in
= (const uint32_t *)inp
;
673 for( size_t i
= 0; i
< samples
; i
++ )
675 uint32_t s
= *(in
++);
677 *(out
++) = (s
>> 16);
678 *(out
++) = (s
>> 24) + 0x80;
682 static void S24BEncode( void *outp
, const uint8_t *inp
, unsigned samples
)
684 const uint32_t *in
= (const uint32_t *)inp
;
687 for( size_t i
= 0; i
< samples
; i
++ )
689 uint32_t s
= *(in
++);
690 *(out
++) = (s
>> 24);
691 *(out
++) = (s
>> 16);
696 static void S24LEncode( void *outp
, const uint8_t *inp
, unsigned samples
)
698 const uint32_t *in
= (const uint32_t *)inp
;
701 for( size_t i
= 0; i
< samples
; i
++ )
703 uint32_t s
= *(in
++);
705 *(out
++) = (s
>> 16);
706 *(out
++) = (s
>> 24);
710 static void U32IEncode( void *outp
, const uint8_t *inp
, unsigned samples
)
712 const uint32_t *in
= (const uint32_t *)inp
;
713 uint32_t *out
= outp
;
715 for( size_t i
= 0; i
< samples
; i
++ )
716 *(out
++) = vlc_bswap32( *(in
++) + 0x80000000 );
719 static void U32NEncode( void *outp
, const uint8_t *inp
, unsigned samples
)
721 const uint32_t *in
= (const uint32_t *)inp
;
722 uint32_t *out
= outp
;
724 for( size_t i
= 0; i
< samples
; i
++ )
725 *(out
++) = *(in
++) + 0x80000000;
728 static void S32IEncode( void *outp
, const uint8_t *inp
, unsigned samples
)
730 const int32_t *in
= (const int32_t *)inp
;
733 for( size_t i
= 0; i
< samples
; i
++ )
734 *(out
++) = vlc_bswap32( *(in
++) );
737 static void F32IEncode( void *outp
, const uint8_t *inp
, unsigned samples
)
739 const float *in
= (const float *)inp
;
742 for( size_t i
= 0; i
< samples
; i
++ )
744 union { float f
; uint32_t u
; char b
[4]; } s
;
747 s
.u
= vlc_bswap32( s
.u
);
748 memcpy( out
, s
.b
, 4 );
753 static void F64IEncode( void *outp
, const uint8_t *inp
, unsigned samples
)
755 const double *in
= (const double *)inp
;
758 for( size_t i
= 0; i
< samples
; i
++ )
760 union { double d
; uint64_t u
; char b
[8]; } s
;
763 s
.u
= vlc_bswap64( s
.u
);
764 memcpy( out
, s
.b
, 8 );
769 static block_t
*Encode( encoder_t
*enc
, block_t
*in
)
774 block_t
*out
= block_Alloc( in
->i_nb_samples
775 * enc
->fmt_out
.audio
.i_bytes_per_frame
);
776 if( unlikely(out
== NULL
) )
779 out
->i_flags
= in
->i_flags
;
780 out
->i_nb_samples
= in
->i_nb_samples
;
781 out
->i_dts
= in
->i_dts
;
782 out
->i_pts
= in
->i_pts
;
783 out
->i_length
= in
->i_length
;
785 void (*encode
)(void *, const uint8_t *, unsigned) = (void *)enc
->p_sys
;
787 encode( out
->p_buffer
, in
->p_buffer
, in
->i_nb_samples
788 * enc
->fmt_out
.audio
.i_channels
);
790 assert( out
->i_buffer
>= in
->i_buffer
);
791 memcpy( out
->p_buffer
, in
->p_buffer
, in
->i_buffer
);
797 * Probes the PCM audio encoder.
799 static int EncoderOpen( vlc_object_t
*p_this
)
801 encoder_t
*p_enc
= (encoder_t
*)p_this
;
802 void (*encode
)(void *, const uint8_t *, unsigned) = NULL
;
804 switch( p_enc
->fmt_out
.i_codec
)
810 p_enc
->fmt_in
.i_codec
= VLC_CODEC_U8
;
811 p_enc
->fmt_out
.audio
.i_bitspersample
= 8;
815 p_enc
->fmt_in
.i_codec
= VLC_CODEC_S16N
;
816 p_enc
->fmt_out
.audio
.i_bitspersample
= 16;
820 p_enc
->fmt_in
.i_codec
= VLC_CODEC_S16N
;
821 p_enc
->fmt_out
.audio
.i_bitspersample
= 16;
827 p_enc
->fmt_in
.i_codec
= VLC_CODEC_S16N
;
828 p_enc
->fmt_out
.audio
.i_bitspersample
= 16;
832 p_enc
->fmt_in
.i_codec
= VLC_CODEC_S32N
;
833 p_enc
->fmt_out
.audio
.i_bitspersample
= 24;
837 p_enc
->fmt_in
.i_codec
= VLC_CODEC_S32N
;
838 p_enc
->fmt_out
.audio
.i_bitspersample
= 24;
842 p_enc
->fmt_in
.i_codec
= VLC_CODEC_S32N
;
843 p_enc
->fmt_out
.audio
.i_bitspersample
= 24;
847 p_enc
->fmt_in
.i_codec
= VLC_CODEC_S32N
;
848 p_enc
->fmt_out
.audio
.i_bitspersample
= 24;
852 p_enc
->fmt_in
.i_codec
= VLC_CODEC_S32N
;
853 p_enc
->fmt_out
.audio
.i_bitspersample
= 32;
857 p_enc
->fmt_in
.i_codec
= VLC_CODEC_S32N
;
858 p_enc
->fmt_out
.audio
.i_bitspersample
= 32;
864 p_enc
->fmt_in
.i_codec
= VLC_CODEC_S32N
;
865 p_enc
->fmt_out
.audio
.i_bitspersample
= 32;
867 #ifdef WORDS_BIGENDIAN
875 p_enc
->fmt_in
.i_codec
= VLC_CODEC_FL32
;
876 p_enc
->fmt_out
.audio
.i_bitspersample
= 32;
878 #ifdef WORDS_BIGENDIAN
886 p_enc
->fmt_in
.i_codec
= VLC_CODEC_FL64
;
887 p_enc
->fmt_out
.audio
.i_bitspersample
= 64;
893 p_enc
->p_sys
= (void *)encode
;
894 p_enc
->pf_encode_audio
= Encode
;
895 p_enc
->fmt_out
.audio
.i_bytes_per_frame
=
896 (p_enc
->fmt_out
.audio
.i_bitspersample
/ 8) *
897 p_enc
->fmt_in
.audio
.i_channels
;
898 p_enc
->fmt_out
.i_bitrate
=
899 p_enc
->fmt_in
.audio
.i_channels
*
900 p_enc
->fmt_in
.audio
.i_rate
*
901 p_enc
->fmt_out
.audio
.i_bitspersample
;
903 msg_Dbg( p_enc
, "samplerate:%dHz channels:%d bits/sample:%d",
904 p_enc
->fmt_out
.audio
.i_rate
, p_enc
->fmt_out
.audio
.i_channels
,
905 p_enc
->fmt_out
.audio
.i_bitspersample
);
909 #endif /* ENABLE_SOUT */