[FFmpeg-devel] [PATCH 1/6] nutenc: keep track of the written syncpoint count
Michael Niedermayer
michaelni at gmx.at
Sun Aug 19 23:39:07 CEST 2012
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
---
libavformat/nut.c | 2 ++
libavformat/nut.h | 1 +
2 files changed, 3 insertions(+)
diff --git a/libavformat/nut.c b/libavformat/nut.c
index 7e3c83a..e160636 100644
--- a/libavformat/nut.c
+++ b/libavformat/nut.c
@@ -140,6 +140,8 @@ void ff_nut_add_sp(NUTContext *nut, int64_t pos, int64_t back_ptr, int64_t ts){
Syncpoint *sp= av_mallocz(sizeof(Syncpoint));
struct AVTreeNode *node= av_mallocz(av_tree_node_size);
+ nut->sp_count++;
+
sp->pos= pos;
sp->back_ptr= back_ptr;
sp->ts= ts;
diff --git a/libavformat/nut.h b/libavformat/nut.h
index 033bc08..cac6870 100644
--- a/libavformat/nut.h
+++ b/libavformat/nut.h
@@ -101,6 +101,7 @@ typedef struct {
int header_count;
AVRational *time_base;
struct AVTreeNode *syncpoints;
+ int sp_count;
} NUTContext;
extern const AVCodecTag ff_nut_subtitle_tags[];
--
1.7.9.5
More information about the ffmpeg-devel
mailing list