changeset 2488:7420572a8d72 libavformat

Use cluster_pos when checking cluster position
author conrad
date Wed, 05 Sep 2007 00:24:53 +0000
parents 9a9c45b95c6f
children 3ef5728030da
files matroskaenc.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/matroskaenc.c	Wed Sep 05 00:24:50 2007 +0000
+++ b/matroskaenc.c	Wed Sep 05 00:24:53 2007 +0000
@@ -677,7 +677,7 @@
     int keyframe = !!(pkt->flags & PKT_FLAG_KEY);
 
     // start a new cluster every 5 MB or 5 sec
-    if (url_ftell(pb) > mkv->cluster + 5*1024*1024 || pkt->pts > mkv->cluster_pts + 5000) {
+    if (url_ftell(pb) > mkv->cluster_pos + 5*1024*1024 || pkt->pts > mkv->cluster_pts + 5000) {
         av_log(s, AV_LOG_DEBUG, "Starting new cluster at offset %llu bytes, pts %llu\n", url_ftell(pb), pkt->pts);
         end_ebml_master(pb, mkv->cluster);