From 657d7ad7ca9a4ab124e36faf1726ab1945bfdbc9 Mon Sep 17 00:00:00 2001 From: Thulinma Date: Mon, 11 May 2015 19:02:00 +0200 Subject: [PATCH] Fixed MP4 playback problems with zero-length parts (Mantrics playback issue). --- src/input/input_mp4.h | 8 ++++++++ src/output/output_progressive_mp4.h | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/src/input/input_mp4.h b/src/input/input_mp4.h index 15e34180..4c842d86 100644 --- a/src/input/input_mp4.h +++ b/src/input/input_mp4.h @@ -13,6 +13,10 @@ namespace Mist { if (time == rhs.time){ if (trackID < rhs.trackID){ return true; + }else{ + if (trackID == rhs.trackID && bpos < rhs.bpos){ + return true; + } } } } @@ -34,6 +38,10 @@ namespace Mist { if (time == rhs.time){ if (trackID < rhs.trackID){ return true; + }else{ + if (trackID == rhs.trackID && bpos < rhs.bpos){ + return true; + } } } } diff --git a/src/output/output_progressive_mp4.h b/src/output/output_progressive_mp4.h index a53a65a1..ed9e15e8 100644 --- a/src/output/output_progressive_mp4.h +++ b/src/output/output_progressive_mp4.h @@ -13,7 +13,7 @@ namespace Mist { return true; } if (trackID == rhs.trackID){ - return endTime < rhs.endTime; + return index < rhs.index; } } return false;