memorymanager: rewrote entire memory management system

This commit is contained in:
itsmattkc
2020-02-23 20:29:51 +11:00
parent 3a90e76fec
commit 48cdb3a6dd
10 changed files with 143 additions and 147 deletions
+4 -7
View File
@@ -34,6 +34,7 @@ extern "C" {
#include "audio/sampleformat.h"
#include "codec/decoder.h"
#include "codec/waveoutput.h"
#include "ffmpegframecache.h"
#include "project/item/footage/videostream.h"
/**
@@ -101,8 +102,8 @@ private:
void CacheFrameToDisk(AVFrame* f);
void RemoveFirstFromFrameCache();
void RemoveLastFromFrameCache();
//void RemoveFirstFromFrameCache();
//void RemoveLastFromFrameCache();
void ClearFrameCache();
void ClearResources();
@@ -116,7 +117,7 @@ private:
SwsContext* scale_ctx_;
QList<AVFrame*> cached_frames_;
FFmpegFrameCache cached_frames_;
bool cache_at_zero_;
bool cache_at_eof_;
@@ -127,12 +128,8 @@ private:
QTimer clear_timer_;
private slots:
void FreeMemory();
void ClearTimerEvent();
void RestartClearTimer();
};
#endif // FFMPEGDECODER_H