demux: adaptive: add buffer length
authorFrancois Cartegnie <fcvlcdev@free.fr>
Mon, 20 Jun 2016 15:29:38 +0000 (17:29 +0200)
committerFrancois Cartegnie <fcvlcdev@free.fr>
Sat, 9 Jul 2016 11:10:55 +0000 (13:10 +0200)
modules/demux/adaptive/plumbing/CommandsQueue.cpp
modules/demux/adaptive/plumbing/CommandsQueue.hpp

index e8d32b7..832abb5 100644 (file)
@@ -314,6 +314,11 @@ void CommandsQueue::setDrop( bool b )
     vlc_mutex_unlock(&lock);
 }
 
+mtime_t CommandsQueue::getDemuxedAmount() const
+{
+    return bufferinglevel - getFirstDTS();
+}
+
 mtime_t CommandsQueue::getBufferingLevel() const
 {
     mtime_t i_buffer;
index e5bed22..b22cc2e 100644 (file)
@@ -145,6 +145,7 @@ namespace adaptive
             void Commit();
             bool isEmpty() const;
             void setDrop( bool );
+            mtime_t getDemuxedAmount() const;
             mtime_t getBufferingLevel() const;
             mtime_t getFirstDTS() const;