-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathidscameramanager.h
63 lines (44 loc) · 1.26 KB
/
idscameramanager.h
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
/*!
* \file idscameramanager.h
* \author IDS Imaging Development Systems GmbH
* \date 2019-05-01
* \since 1.0.0
*
* \version 1.0.0
*
*/
#ifndef IDSCAMERAMANAGER_H
#define IDSCAMERAMANAGER_H
#include "acquisitionworker.h"
#include <peak_ipl/peak_ipl.hpp>
#include <peak/peak.hpp>
#include <cstdint>
#include "opencv2/opencv.hpp"
#include <opencv2/core/core.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/videoio.hpp>
class IdsCameraManager{
enum autoExposure {Off, Once, Continuous};
public:
explicit IdsCameraManager();
~IdsCameraManager();
cv::Mat getFrame();
bool isRunning();
int getHeight();
int getWidth();
unsigned int frameCounter();
void setFrameRate(double framerate);
double getFrameRate();
void setAutoExposure(autoExposure mode);
private:
std::shared_ptr<peak::core::Device> m_device;
std::shared_ptr<peak::core::DataStream> m_dataStream;
std::shared_ptr<peak::core::NodeMap> m_nodemapRemoteDevice;
AcquisitionWorker* m_acquisitionWorker;
void DestroyAll();
bool OpenDevice();
void CloseDevice();
void onCounterUpdated(unsigned int frameCounter, unsigned int errorCounter);
};
#endif // IDSCAMERAMANAGER_H