50 lines
1.3 KiB
C++
50 lines
1.3 KiB
C++
#ifndef APICONTROLLER_H
|
|
#define APICONTROLLER_H
|
|
|
|
#include <string>
|
|
#include <VimbaCPP/Include/VimbaCPP.h>
|
|
|
|
namespace AVT {
|
|
namespace VmbAPI {
|
|
namespace Examples {
|
|
|
|
class FrameObserver;
|
|
|
|
class ApiController
|
|
{
|
|
public:
|
|
typedef AVT::VmbAPI::CameraPtrVector CameraPtrVector;
|
|
typedef AVT::VmbAPI::FramePtr FramePtr;
|
|
|
|
ApiController();
|
|
~ApiController();
|
|
|
|
VmbErrorType StartUp();
|
|
void ShutDown();
|
|
VmbErrorType StartContinuousImageAcquisition(const std::string& cameraID);
|
|
VmbErrorType StopContinuousImageAcquisition();
|
|
CameraPtrVector GetCameraList();
|
|
FramePtr GetFrame();
|
|
VmbErrorType QueueFrame(FramePtr pFrame);
|
|
void ClearFrameQueue();
|
|
|
|
int GetWidth() const;
|
|
int GetHeight() const;
|
|
VmbPixelFormatType GetPixelFormat() const;
|
|
|
|
private:
|
|
AVT::VmbAPI::VimbaSystem& m_system;
|
|
AVT::VmbAPI::CameraPtr m_pCamera;
|
|
AVT::VmbAPI::IFrameObserverPtr m_pFrameObserver;
|
|
VmbInt64_t m_nPixelFormat;
|
|
VmbInt64_t m_nWidth;
|
|
VmbInt64_t m_nHeight;
|
|
|
|
VmbErrorType SetValueIntMod2(const AVT::VmbAPI::CameraPtr &camera,
|
|
const std::string &featureName,
|
|
VmbInt64_t &storage);
|
|
};
|
|
|
|
}}} // namespace AVT::VmbAPI::Examples
|
|
|
|
#endif |