From 68893afe1d4583038d3788b6c3e462e42ce6074d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Storsj=C3=B6?= Date: Thu, 22 Mar 2012 13:31:31 +0200 Subject: movenc: Merge if statements MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This isn't exactly equivalent with the earlier code for codecs other than H264 and VC1, but those are two only codecs supported by this codepath anyway, and it simplifies it a bit. Signed-off-by: Martin Storsjö --- libavformat/movenc.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'libavformat') diff --git a/libavformat/movenc.c b/libavformat/movenc.c index a832c1d..1d808f1 100644 --- a/libavformat/movenc.c +++ b/libavformat/movenc.c @@ -2147,14 +2147,11 @@ static int mov_write_isml_manifest(AVIOContext *pb, MOVMuxContext *mov) size); av_free(ptr); } - } else { - param_write_hex(pb, "CodecPrivateData", track->enc->extradata, - track->enc->extradata_size); - } - if (track->enc->codec_id == CODEC_ID_H264) { param_write_string(pb, "FourCC", "H264"); } else if (track->enc->codec_id == CODEC_ID_VC1) { param_write_string(pb, "FourCC", "WVC1"); + param_write_hex(pb, "CodecPrivateData", track->enc->extradata, + track->enc->extradata_size); } param_write_int(pb, "MaxWidth", track->enc->width); param_write_int(pb, "MaxHeight", track->enc->height); -- cgit v1.1