setstreamVodField and streamLiveField no longer mutually exclusive

Removed curPage map from IO. bufferFrame now creates this variable locally and passes it to bufferStart, bufferFinalize and bufferNext
Fix keyNum selection with mixed live & VoD data
Fix bufferframe to handle mixed VoD and live
Added check to bufferFrame to not start the countdown timer for removing live pages
Fixed countdown timer being set using keyNum rather than pageNumber, which resulted in the wrong pages being deleted
livePage variable moved from static to private variable to correctly handle multithreaded inputs

# Conflicts:
#	src/io.cpp
#	src/output/output.cpp
This commit is contained in:
Marco van Dijk 2021-11-22 10:47:34 +01:00 committed by Thulinma
parent d1358400f7
commit 3d9ed39396
13 changed files with 241 additions and 150 deletions

View file

@ -170,6 +170,9 @@ static inline void show_stackframe(){}
#define DEFAULT_FRAGMENT_DURATION 1900
// Pages get marked for deletion after X seconds of no one watching
#define DEFAULT_PAGE_TIMEOUT 15
/// \TODO These values are hardcoded and that is dangerous and probably a very bad idea. I don't even know if they are currently correct...?! I doubt they are.
#define META_META_OFFSET 104
#define META_META_RECORDSIZE 576