Commit b69ad311 authored by Ilkka Ollakka's avatar Ilkka Ollakka

mux: add case for MP3 in muxers as it's not different codec that default mpga

parent fe5063ec
......@@ -374,22 +374,20 @@ static int AddStream( sout_mux_t *p_mux, sout_input_t *p_input )
tk->psz_name = "MPEG-4 Audio";
i_bitspersample = 0;
break;
case VLC_CODEC_MPGA:
#if 1
case VLC_CODEC_MP3:
tk->psz_name = "MPEG Audio Layer 3";
tk->i_tag = WAVE_FORMAT_MPEGLAYER3;
i_bitspersample = 0;
i_blockalign = 1;
i_extra = 12;
break;
#else
case VLC_CODEC_MPGA:
tk->psz_name = "MPEG Audio Layer 1/2";
tk->i_tag = WAVE_FORMAT_MPEG;
i_bitspersample = 0;
i_blockalign = 1;
i_extra = 22;
break;
#endif
case VLC_CODEC_WMA1:
tk->psz_name = "Windows Media Audio v1";
tk->i_tag = WAVE_FORMAT_WMA1;
......
......@@ -343,7 +343,7 @@ static int AddStream( sout_mux_t *p_mux, sout_input_t *p_input )
p_wf->wFormatTag = WAVE_FORMAT_A52;
p_wf->nBlockAlign= 1;
break;
case VLC_CODEC_MPGA:
case VLC_CODEC_MP3:
p_wf->wFormatTag = WAVE_FORMAT_MPEGLAYER3;
p_wf->nBlockAlign= 1;
break;
......
......@@ -935,6 +935,7 @@ static int AddStream( sout_mux_t *p_mux, sout_input_t *p_input )
/* AUDIO */
case VLC_CODEC_MPGA:
case VLC_CODEC_MP3:
p_stream->i_stream_type =
p_input->p_fmt->audio.i_rate >= 32000 ? 0x03 : 0x04;
p_stream->i_stream_id = 0xc0;
......@@ -1289,7 +1290,8 @@ static bool MuxStreams(sout_mux_t *p_mux )
block_t *p_data;
if( p_stream == p_pcr_stream || p_sys->b_data_alignment
|| p_input->p_fmt->i_codec != VLC_CODEC_MPGA )
|| ((p_input->p_fmt->i_codec != VLC_CODEC_MPGA ) &&
(p_input->p_fmt->i_codec != VLC_CODEC_MP3) ) )
{
p_data = block_FifoGet( p_input->p_fifo );
if (p_data->i_pts <= VLC_TS_INVALID)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment