Commit b617ab5f authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

avcodec: fix mpeg-1 encoding

parent 88ade576
...@@ -220,6 +220,12 @@ int OpenEncoder( vlc_object_t *p_this ) ...@@ -220,6 +220,12 @@ int OpenEncoder( vlc_object_t *p_this )
i_codec_id = CODEC_ID_MP2; i_codec_id = CODEC_ID_MP2;
psz_namecodec = "MPEG I/II Layer 2"; psz_namecodec = "MPEG I/II Layer 2";
} }
else if( p_enc->fmt_out.i_codec == VLC_CODEC_MP1V )
{
i_cat = VIDEO_ES;
i_codec_id = CODEC_ID_MPEG1VIDEO;
psz_namecodec = "MPEG-1 video";
}
else if( !GetFfmpegCodec( p_enc->fmt_out.i_codec, &i_cat, &i_codec_id, else if( !GetFfmpegCodec( p_enc->fmt_out.i_codec, &i_cat, &i_codec_id,
&psz_namecodec ) ) &psz_namecodec ) )
{ {
...@@ -466,8 +472,7 @@ int OpenEncoder( vlc_object_t *p_this ) ...@@ -466,8 +472,7 @@ int OpenEncoder( vlc_object_t *p_this )
p_context->b_frame_strategy = 0; p_context->b_frame_strategy = 0;
if( !p_context->max_b_frames && if( !p_context->max_b_frames &&
( p_enc->fmt_out.i_codec == VLC_CODEC_MPGV || ( p_enc->fmt_out.i_codec == VLC_CODEC_MPGV ||
p_enc->fmt_out.i_codec == VLC_CODEC_MP2V || p_enc->fmt_out.i_codec == VLC_CODEC_MP2V ) )
p_enc->fmt_out.i_codec == VLC_CODEC_MP1V ) )
p_context->flags |= CODEC_FLAG_LOW_DELAY; p_context->flags |= CODEC_FLAG_LOW_DELAY;
if( p_enc->fmt_out.i_codec == VLC_CODEC_MP2V ) if( p_enc->fmt_out.i_codec == VLC_CODEC_MP2V )
......
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