Fixed audio key setting

This commit is contained in:
Thulinma 2017-07-22 19:07:16 +02:00
parent 5a6eaa30ac
commit 2f477a4ef9
3 changed files with 2 additions and 3 deletions

View file

@ -93,6 +93,7 @@ static inline void show_stackframe(){}
#define SHM_DATASIZE 20
#endif
#define AUDIO_KEY_INTERVAL 5000 ///< This define controls the keyframe interval for non-video tracks, such as audio and metadata tracks.
#ifndef STATS_DELAY
#define STATS_DELAY 15

View file

@ -6,8 +6,6 @@
#include <iomanip>
#include <fstream>
#define AUDIO_KEY_INTERVAL 5000 ///< This define controls the keyframe interval for non-video tracks, such as audio and metadata tracks.
namespace DTSC {
/// Default constructor for packets - sets a null pointer and invalid packet.
Packet::Packet() {

View file

@ -453,7 +453,7 @@ namespace Mist {
isKeyframe = true;
} else {
unsigned long lastKey = pagesByTrack[tid].rbegin()->second.lastKeyTime;
if (packet.getTime() - lastKey > 5000) {
if (packet.getTime() - lastKey > AUDIO_KEY_INTERVAL) {
isKeyframe = true;
}
}