summaryrefslogtreecommitdiff
path: root/libavformat
diff options
context:
space:
mode:
authorJohn Stebbins <stebbins@jetheaddev.com>2014-08-04 13:13:44 -0700
committerLuca Barbato <lu_zero@gentoo.org>2014-08-05 11:36:08 +0200
commit0897d2fdc7755849c3ae58d8b543ef734c200d3c (patch)
tree7f6bb11544c92bff24d43dce0b2b2e9b8c3c9af1 /libavformat
parent2601a9447efb778930b01ac58d2cc1d02498db4e (diff)
movenc: Add option to disable nero chapters
And add flag to muxer documentation. Nero chapters break some taggers (mp3tag and iTunes). Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/movenc.c3
-rw-r--r--libavformat/movenc.h1
2 files changed, 3 insertions, 1 deletions
diff --git a/libavformat/movenc.c b/libavformat/movenc.c
index f16e851245..73a78d8010 100644
--- a/libavformat/movenc.c
+++ b/libavformat/movenc.c
@@ -57,6 +57,7 @@ static const AVOption options[] = {
{ "isml", "Create a live smooth streaming feed (for pushing to a publishing point)", 0, AV_OPT_TYPE_CONST, {.i64 = FF_MOV_FLAG_ISML}, INT_MIN, INT_MAX, AV_OPT_FLAG_ENCODING_PARAM, "movflags" },
{ "faststart", "Run a second pass to put the index (moov atom) at the beginning of the file", 0, AV_OPT_TYPE_CONST, {.i64 = FF_MOV_FLAG_FASTSTART}, INT_MIN, INT_MAX, AV_OPT_FLAG_ENCODING_PARAM, "movflags" },
{ "omit_tfhd_offset", "Omit the base data offset in tfhd atoms", 0, AV_OPT_TYPE_CONST, {.i64 = FF_MOV_FLAG_OMIT_TFHD_OFFSET}, INT_MIN, INT_MAX, AV_OPT_FLAG_ENCODING_PARAM, "movflags" },
+ { "disable_chpl", "Disable Nero chapter atom", 0, AV_OPT_TYPE_CONST, {.i64 = FF_MOV_FLAG_DISABLE_CHPL}, INT_MIN, INT_MAX, AV_OPT_FLAG_ENCODING_PARAM, "movflags" },
FF_RTP_FLAG_OPTS(MOVMuxContext, rtp_flags),
{ "skip_iods", "Skip writing iods atom.", offsetof(MOVMuxContext, iods_skip), AV_OPT_TYPE_INT, {.i64 = 0}, 0, 1, AV_OPT_FLAG_ENCODING_PARAM},
{ "iods_audio_profile", "iods audio profile atom.", offsetof(MOVMuxContext, iods_audio_profile), AV_OPT_TYPE_INT, {.i64 = -1}, -1, 255, AV_OPT_FLAG_ENCODING_PARAM},
@@ -2076,7 +2077,7 @@ static int mov_write_udta_tag(AVIOContext *pb, MOVMuxContext *mov,
mov_write_meta_tag(pb_buf, mov, s);
}
- if (s->nb_chapters)
+ if (s->nb_chapters && !(mov->flags & FF_MOV_FLAG_DISABLE_CHPL))
mov_write_chpl_tag(pb_buf, s);
if ((size = avio_close_dyn_buf(pb_buf, &buf)) > 0) {
diff --git a/libavformat/movenc.h b/libavformat/movenc.h
index 35be7818ed..0d3eb34c5e 100644
--- a/libavformat/movenc.h
+++ b/libavformat/movenc.h
@@ -175,6 +175,7 @@ typedef struct MOVMuxContext {
#define FF_MOV_FLAG_ISML 64
#define FF_MOV_FLAG_FASTSTART 128
#define FF_MOV_FLAG_OMIT_TFHD_OFFSET 256
+#define FF_MOV_FLAG_DISABLE_CHPL 512
int ff_mov_write_packet(AVFormatContext *s, AVPacket *pkt);