diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2008-06-12 03:08:41 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2008-06-12 03:08:41 +0000 |
commit | a04aec6d1aa80ea4fbac9df633419f6641068c4d (patch) | |
tree | 5c2557c3fd9d78293d3701074df555ad686306cf | |
parent | 2c77994fc8a3e850d38a20587c231a56e285ee8d (diff) | |
download | ffmpeg-a04aec6d1aa80ea4fbac9df633419f6641068c4d.tar.gz |
simplify MODE_3G2
Originally committed as revision 13755 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavformat/movenc.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libavformat/movenc.c b/libavformat/movenc.c index cd2d25728c..57cbc56c91 100644 --- a/libavformat/movenc.c +++ b/libavformat/movenc.c @@ -526,7 +526,7 @@ static int mov_find_codec_tag(AVFormatContext *s, MOVTrack *track) if (!match_ext(s->filename, "m4a") && !match_ext(s->filename, "m4v")) av_log(s, AV_LOG_WARNING, "Warning, extension is not .m4a nor .m4v " "Quicktime/Ipod might not play the file\n"); - } else if (track->mode == MODE_3GP || track->mode == MODE_3G2) { + } else if (track->mode & MODE_3GP) { tag = codec_get_tag(codec_3gp_tags, track->enc->codec_id); } else if (!tag || (track->enc->strict_std_compliance >= FF_COMPLIANCE_NORMAL && (tag == MKTAG('d','v','c','p') || @@ -1255,7 +1255,7 @@ static int mov_write_udta_tag(ByteIOContext *pb, MOVContext *mov, put_be32(pb, 0); /* size */ put_tag(pb, "udta"); - if (mov->mode == MODE_3GP || mov->mode == MODE_3G2) { + if (mov->mode & MODE_3GP) { mov_write_3gp_udta_tag(pb, s, "titl", s->title); mov_write_3gp_udta_tag(pb, s, "auth", s->author); mov_write_3gp_udta_tag(pb, s, "gnre", s->genre); @@ -1384,7 +1384,7 @@ static void mov_write_ftyp_tag(ByteIOContext *pb, AVFormatContext *s) if (mov->mode == MODE_3GP) put_tag(pb, "3gp4"); - else if (mov->mode == MODE_3G2) + else if (mov->mode & MODE_3G2) put_tag(pb, "3g2a"); else if (mov->mode == MODE_PSP) put_tag(pb, "MSNV"); @@ -1405,7 +1405,7 @@ static void mov_write_ftyp_tag(ByteIOContext *pb, AVFormatContext *s) if (mov->mode == MODE_3GP) put_tag(pb, "3gp4"); - else if (mov->mode == MODE_3G2) + else if (mov->mode & MODE_3G2) put_tag(pb, "3g2a"); else if (mov->mode == MODE_PSP) put_tag(pb, "MSNV"); @@ -1494,7 +1494,7 @@ static int mov_write_header(AVFormatContext *s) if (s->oformat != NULL) { if (!strcmp("3gp", s->oformat->name)) mov->mode = MODE_3GP; - else if (!strcmp("3g2", s->oformat->name)) mov->mode = MODE_3G2; + else if (!strcmp("3g2", s->oformat->name)) mov->mode = MODE_3GP|MODE_3G2; else if (!strcmp("mov", s->oformat->name)) mov->mode = MODE_MOV; else if (!strcmp("psp", s->oformat->name)) mov->mode = MODE_PSP; else if (!strcmp("ipod",s->oformat->name)) mov->mode = MODE_IPOD; |