18 #ifndef __DEPTH2KIN_MODULE_H__
19 #define __DEPTH2KIN_MODULE_H__
25 #include <opencv2/opencv.hpp>
27 #include <yarp/os/all.h>
28 #include <yarp/sig/all.h>
29 #include <yarp/dev/all.h>
38 using namespace yarp::os;
40 using namespace yarp::sig;
52 void onRead(ImageOf<PixelMono> &imgIn);
111 motorExplorationStateLog } motorExplorationState;
122 bool attach(RpcServer &source);
123 bool createTargets(
const Vector &c,
const Vector &size);
124 bool isTypeValid(
const string &type);
126 bool factory(Value &v);
127 cv::Rect extractFingerTip(ImageOf<PixelMono> &imgIn, ImageOf<PixelBgr> &imgOut,
128 const Vector &c, Vector &px);
129 double getMinVer()
const;
130 bool getGazeParams(
const string &eye,
const string &type, Matrix &M);
131 bool pushExtrinsics(
const string &eye,
const Matrix &
H);
132 bool getDepth(
const Vector &px, Vector &
x, Vector &pxr);
133 bool getDepthAveraged(
const Vector &px, Vector &
x, Vector &pxr,
const int maxSamples=5);
134 void openHand(IControlMode *imod, IPositionControl *ipos);
135 void postureHelper(
const Vector &gaze_ang,
const Matrix &targetL,
const Matrix &targetR);
137 int removeOutliers();
138 void doMotorExploration();
139 void doTouch(
const Vector &xd);
144 bool configure(ResourceFinder &rf);
145 void onRead(ImageOf<PixelMono> &imgIn);
156 bool log(
const string &type);
159 bool setMaxDist(
const double max_dist);
161 bool setRoi(
const int side);
163 bool setBlockEyes(
const double block_eyes);
164 double getBlockEyes();
167 bool setArm(
const string &arm);
169 bool setCalibrationType(
const string &type,
const string &extrapolation);
170 string getCalibrationType();
171 Property
calibrate(
const bool rm_outliers);
172 bool pushCalibrator();
173 bool setTouchWithExperts(
const string &sw);
174 string getTouchWithExperts();
175 bool touch(
const int u,
const int v);
176 PointReq getPoint(
const string &arm,
const double x,
const double y,
const double z);
177 vector<PointReq> getPoints(
const string &arm,
const vector<double> &coordinates);
178 bool setExperiment(
const string &
exp,
const string &v);
179 string getExperiment(
const string &
exp);
180 Vector getExtrinsics(
const string &eye);
181 bool resetExtrinsics(
const string &eye);
182 bool setExplorationWait(
const double wait);
183 double getExplorationWait();
184 bool setExplorationInTargetTol(
const double tol);
185 double getExplorationInTargetTol();
186 bool setTouchInTargetTol(
const double tol);
187 double getTouchInTargetTol();
188 bool setExplorationSpace(
const double cx,
const double cy,
const double cz,
189 const double a,
const double b);
190 bool setExplorationSpaceDelta(
const double dcx,
const double dcy,
const double dcz,
191 const double da,
const double db);
192 Property getExplorationData();
193 bool clearExplorationData();
194 bool posture(
const string &type);
195 bool calibrateDepth();
bool motorExplorationAsyncStop
IEncoderArrays * iencarray
Vector curExplorationCenter
double exploration_intargettol
@ motorExplorationStateTrigger
@ motorExplorationStateReach
@ motorExplorationStateIdle
DisparityProcessor depthInPort
BufferedPort< ImageOf< PixelBgr > > depthOutPort
BufferedPort< Bottle > touchInPort
LocallyWeightedExperts * experts
PointReq IDL structure to send/receive points.
depth2kin_IDL IDL Interface to depth2kin services.
A class for defining the iCub Finger.