forked from alessandroferrari/MuHi
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTarget.cpp
41 lines (27 loc) · 865 Bytes
/
Target.cpp
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
#include <opencv2/opencv.hpp>
#include <iostream>
#include <stdio.h>
#include <fstream>
#include <vector>
using namespace std;
class Target{
public:
cv::Point target;
cv::Rect face;
cv::Point leftPupil;
cv::Point rightPupil;
Target(cv::Point t, cv::Rect _face, cv::Point lP, cv::Point rP){
target = t;
face = _face;
leftPupil = lP;
rightPupil = rP;
}
std::string toString(){
std::stringstream out;
out << "Target point at: " << target.x << " - " << target.y << "\n"<<endl;
out << "Face at: "<<face.x << " - " << face.y << "\n"<<endl;
out << "leftPupil at: " << leftPupil.x << " - " <<leftPupil.y << "\n"<<endl;
out << "rightPupil at: " << rightPupil.x << " - " << rightPupil.y << "\n"<<endl;
return out.str();
}
};