v3.3.t7
-detect loop will now use the previous video clip as a base for the next 3 video clips. doing this prevents the same clips from being processed multiple times.
This commit is contained in:
parent
5b444fd754
commit
da941d8d18
|
@ -167,9 +167,6 @@ void DetectLoop::init()
|
|||
|
||||
void DetectLoop::reset()
|
||||
{
|
||||
vidAPath.clear();
|
||||
vidBPath.clear();
|
||||
|
||||
eventQue.inQue = false;
|
||||
eventQue.score = 0;
|
||||
eventQue.queAge = 0;
|
||||
|
@ -182,15 +179,19 @@ void DetectLoop::reset()
|
|||
void DetectLoop::updated(const QString &path)
|
||||
{
|
||||
auto clips = lsFilesInDir(path, shared->streamExt);
|
||||
auto index = clips.indexOf(vidBName);
|
||||
|
||||
if (clips.size() < 3)
|
||||
if (clips.size() - (index + 1) < 3)
|
||||
{
|
||||
thread()->sleep(5); reset();
|
||||
thread()->sleep(1);
|
||||
}
|
||||
else
|
||||
{
|
||||
vidAPath = shared->buffPath + "/live/" + clips[clips.size() - 3];
|
||||
vidBPath = shared->buffPath + "/live/" + clips[clips.size() - 2];
|
||||
vidAName = clips[clips.size() - 3];
|
||||
vidBName = clips[clips.size() - 2];
|
||||
|
||||
vidAPath = shared->buffPath + "/live/" + vidAName;
|
||||
vidBPath = shared->buffPath + "/live/" + vidBName;
|
||||
|
||||
exec(); thread()->sleep(1);
|
||||
}
|
||||
|
|
|
@ -62,6 +62,8 @@ private:
|
|||
|
||||
QString vidAPath;
|
||||
QString vidBPath;
|
||||
QString vidAName;
|
||||
QString vidBName;
|
||||
QStringList prevClips;
|
||||
QTimer *pcTimer;
|
||||
evt_t eventQue;
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
|
||||
using namespace std;
|
||||
|
||||
#define APP_VER "3.3.t6"
|
||||
#define APP_VER "3.3.t7"
|
||||
#define APP_NAME "Motion Watch"
|
||||
#define APP_BIN "mow"
|
||||
#define DATETIME_FMT "yyyyMMddhhmmss"
|
||||
|
|
Loading…
Reference in New Issue
Block a user