diff options
Diffstat (limited to 'UI')
-rw-r--r-- | UI/DASHPlayerNoGUI.cpp | 2 | ||||
-rw-r--r-- | UI/ViperGui.cpp | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/UI/DASHPlayerNoGUI.cpp b/UI/DASHPlayerNoGUI.cpp index d212b556..2195b88a 100644 --- a/UI/DASHPlayerNoGUI.cpp +++ b/UI/DASHPlayerNoGUI.cpp @@ -89,6 +89,8 @@ DASHPlayerNoGUI::DASHPlayerNoGUI(int argc, char ** argv, pthread_cond_t *mainCon webSocketService.start(); this->parameterAdaptation->segmentDuration = this->mpdWrapper->onFirstDownloadMPD(NULL); this->multimediaManager->setSegmentDuration(this->parameterAdaptation->segmentDuration); + //should be in seconds + this->parameterAdaptation->segmentDuration = this->parameterAdaptation->segmentDuration / 1000.0; this->onStartButtonPressed(0,0,0,0,0); this->multimediaManager->setLooping(this->repeat); } diff --git a/UI/ViperGui.cpp b/UI/ViperGui.cpp index e23bd308..99d2e5a3 100644 --- a/UI/ViperGui.cpp +++ b/UI/ViperGui.cpp @@ -192,7 +192,7 @@ void ViperGui::writeData(libdash::framework::input::MediaObject* media) this->segment = this->segment + 1; if( this->segment > 0) { - this->bufferDuration += this->segmentDuration; + this->bufferDuration += media->GetSegmentDuration(); if(this->bufferDuration - this->position > 3000) { @@ -206,7 +206,7 @@ void ViperGui::writeData(libdash::framework::input::MediaObject* media) } else { - this->bufferDuration += (this->durationMilliseconds - (this->segmentDuration * (this->listSegmentSize - 1))); + this->bufferDuration += (this->durationMilliseconds - (media->GetSegmentDuration() * (this->listSegmentSize - 1))); if(this->bufferDuration - this->position >3000) { |