[vlc-commits] demux: adaptative: add discontinuity flag on segments and chunks

Francois Cartegnie git at videolan.org
Tue Oct 6 13:16:35 CEST 2015


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Mon Oct  5 23:39:41 2015 +0200| [fe5049dde31604f5edf00a14ca24f9fc8cb08e64] | committer: Francois Cartegnie

demux: adaptative: add discontinuity flag on segments and chunks

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=fe5049dde31604f5edf00a14ca24f9fc8cb08e64
---

 modules/demux/adaptative/playlist/Segment.cpp      |    1 +
 modules/demux/adaptative/playlist/Segment.h        |    1 +
 modules/demux/adaptative/playlist/SegmentChunk.cpp |    1 +
 modules/demux/adaptative/playlist/SegmentChunk.hpp |    1 +
 4 files changed, 4 insertions(+)

diff --git a/modules/demux/adaptative/playlist/Segment.cpp b/modules/demux/adaptative/playlist/Segment.cpp
index 64f2dc8..aa8168c 100644
--- a/modules/demux/adaptative/playlist/Segment.cpp
+++ b/modules/demux/adaptative/playlist/Segment.cpp
@@ -49,6 +49,7 @@ ISegment::ISegment(const ICanonicalUrl *parent):
     chunksuse.Set(0);
     sequence = SEQUENCE_INVALID;
     templated = false;
+    discontinuity = false;
 }
 
 ISegment::~ISegment()
diff --git a/modules/demux/adaptative/playlist/Segment.h b/modules/demux/adaptative/playlist/Segment.h
index 7ba7619..c7d1213 100644
--- a/modules/demux/adaptative/playlist/Segment.h
+++ b/modules/demux/adaptative/playlist/Segment.h
@@ -68,6 +68,7 @@ namespace adaptative
                 Property<stime_t>       startTime;
                 Property<stime_t>       duration;
                 Property<unsigned>      chunksuse;
+                bool                    discontinuity;
 
                 static const int CLASSID_ISEGMENT = 0;
                 /* callbacks */
diff --git a/modules/demux/adaptative/playlist/SegmentChunk.cpp b/modules/demux/adaptative/playlist/SegmentChunk.cpp
index 6f6c096..6e015bd 100644
--- a/modules/demux/adaptative/playlist/SegmentChunk.cpp
+++ b/modules/demux/adaptative/playlist/SegmentChunk.cpp
@@ -31,6 +31,7 @@ SegmentChunk::SegmentChunk(ISegment *segment_, const std::string &url) :
     segment = segment_;
     segment->chunksuse.Set(segment->chunksuse.Get() + 1);
     rep = NULL;
+    discontinuity = segment_->discontinuity;
 }
 
 SegmentChunk::~SegmentChunk()
diff --git a/modules/demux/adaptative/playlist/SegmentChunk.hpp b/modules/demux/adaptative/playlist/SegmentChunk.hpp
index 7682d24..57650ff 100644
--- a/modules/demux/adaptative/playlist/SegmentChunk.hpp
+++ b/modules/demux/adaptative/playlist/SegmentChunk.hpp
@@ -42,6 +42,7 @@ namespace adaptative
             void setRepresentation(BaseRepresentation *);
             virtual void onDownload(block_t **); // reimpl
             StreamFormat getStreamFormat() const;
+            bool discontinuity;
 
         protected:
             ISegment *segment;



More information about the vlc-commits mailing list