派生自 development/c++

pansen
2019-03-07 d3b7bbe7102cd089680a828f5d8f6402c8cf6342
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#ifndef LOOPVIDEORECORDER_H
#define LOOPVIDEORECORDER_H
 
#include <iostream>
#include <thread>
#include <functional>
#include <unistd.h>
#include "VideoRecorder.h"
#include <QtCore/QObject>
#include "TimerElement.h"
#include <queue>
 
class LoopVideoRecorder : public TimerElement {
 
public:
    explicit LoopVideoRecorder(int interval, std::string index, std::string rtsp,std::string pathId,LDBTool* db_c);
 
    ~LoopVideoRecorder();
 
    void loopRecordVideo();
 
    void stopTimer();
 
private:
    virtual void timerFunc() override;
    std::string getFullFileName();
 
private:
    std::string m_nIndex;
    std::string m_strRtsp;
    std::string m_pathId;
    int m_nInterval;
    VideoRecorder *m_pVideoRcd;
    std::queue<VideoRecorder *> m_queManager;
    LDBTool* m_db;
};
 
#endif // LOOPVIDEORECORDER_H