YARP
Yet Another Robot Platform
 
Loading...
Searching...
No Matches
FrameGrabberControls_Forwarder.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2006-2021 Istituto Italiano di Tecnologia (IIT)
3 * SPDX-License-Identifier: BSD-3-Clause
4 */
5
6#ifndef YARP_FRAMEGRABBER_PROTOCOL_FRAMEGRABBERCONTROLS_FORWARDER_H
7#define YARP_FRAMEGRABBER_PROTOCOL_FRAMEGRABBERCONTROLS_FORWARDER_H
8
10#include <yarp/os/Port.h>
11
13
20{
21private:
22 yarp::os::Port& m_port;
23
24public:
26 ~FrameGrabberControls_Forwarder() override = default;
27
28 bool getCameraDescription(CameraDescriptor* camera) override;
29 bool hasFeature(int feature, bool* hasFeature) override;
30 bool setFeature(int feature, double value) override;
31 bool getFeature(int feature, double* value) override;
32 bool setFeature(int feature, double value1, double value2) override;
33 bool getFeature(int feature, double* value1, double* value2) override;
34 bool hasOnOff(int feature, bool* HasOnOff) override;
35 bool setActive(int feature, bool onoff) override;
36 bool getActive(int feature, bool* isActive) override;
37 bool hasAuto(int feature, bool* hasAuto) override;
38 bool hasManual(int feature, bool* hasManual) override;
39 bool hasOnePush(int feature, bool* hasOnePush) override;
40 bool setMode(int feature, FeatureMode mode) override;
41 bool getMode(int feature, FeatureMode* mode) override;
42 bool setOnePush(int feature) override;
43
44private:
45 bool setCommand(int code, double v);
46 bool setCommand(int code, double b, double r);
47 double getCommand(int code) const;
48 bool getCommand(int code, double &b, double &r) const;
49
50};
51
52} // namespace yarp::proto::framegrabber
53
54#endif // YARP_FRAMEGRABBER_PROTOCOL_FRAMEGRABBERCONTROLS_FORWARDER_H
Control interface for frame grabber devices.
A mini-server for network communication.
Definition Port.h:46
This classes implement a sender / parser for IFrameGrabberControls interface messages.
bool hasAuto(int feature, bool *hasAuto) override
Check if the requested feature has the 'auto' mode.
bool setActive(int feature, bool onoff) override
Set the requested feature on or off.
bool hasFeature(int feature, bool *hasFeature) override
Check if camera has the requested feature (saturation, brightness ... )
bool getActive(int feature, bool *isActive) override
Get the current status of the feature, on or off.
bool setOnePush(int feature) override
Set the requested feature to a value (saturation, brightness ... )
bool hasOnePush(int feature, bool *hasOnePush) override
Check if the requested feature has the 'onePush' mode.
bool setFeature(int feature, double value) override
Set the requested feature to a value (saturation, brightness ... )
bool getFeature(int feature, double *value) override
Get the current value for the requested feature.
bool hasManual(int feature, bool *hasManual) override
Check if the requested feature has the 'manual' mode.
bool getMode(int feature, FeatureMode *mode) override
Get the current mode for the feature.
bool hasOnOff(int feature, bool *HasOnOff) override
Check if the camera has the ability to turn on/off the requested feature.
bool getCameraDescription(CameraDescriptor *camera) override
Get a basic description of the camera hw.
bool setMode(int feature, FeatureMode mode) override
Set the requested mode for the feature.