48 lines
1007 B
C++
48 lines
1007 B
C++
#ifndef STREAM_MANAGER_H
|
|
#define STREAM_MANAGER_H
|
|
|
|
#include <QObject>
|
|
#include <QDebug>
|
|
|
|
#include <PvSystem.h>
|
|
#include <PvDevice.h>
|
|
#include <PvStream.h>
|
|
#include <PvPipeline.h>
|
|
#include <PvDeviceGEV.h>
|
|
#include <PvStreamGEV.h>
|
|
#include "StreamReader.hpp"
|
|
|
|
#define BUFFER_COUNT (32)
|
|
|
|
class StreamManager : public QObject
|
|
{
|
|
Q_OBJECT;
|
|
|
|
public:
|
|
StreamManager(QObject *parent);
|
|
virtual ~StreamManager();
|
|
|
|
public slots:
|
|
void SetEmissivity(double emissivity);
|
|
void SendForProcessing(uint32_t width, uint32_t height, uint8_t *imgPointer);
|
|
|
|
private:
|
|
PvResult FindDevice();
|
|
PvResult ConnectToDevice();
|
|
PvResult OpenStream();
|
|
void ConfigureStream();
|
|
void StartStream();
|
|
void StopStream();
|
|
void CreatePipeline();
|
|
void AcquireImages();
|
|
void Disconnect();
|
|
|
|
PvString ConnectionID;
|
|
PvDevice *Device = NULL;
|
|
PvStream *Stream = NULL;
|
|
PvGenParameterArray *lDeviceParams = NULL;
|
|
PvPipeline *Pipeline = NULL;
|
|
StreamReader *ImageThread;
|
|
};
|
|
|
|
#endif |