-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path_face_detect_algorithm_8cpp_source.html
More file actions
executable file
·158 lines (156 loc) · 108 KB
/
Copy path_face_detect_algorithm_8cpp_source.html
File metadata and controls
executable file
·158 lines (156 loc) · 108 KB
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.13"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>CortexRobot: /temp/des/CameraTest_nofreev_branch/Algorithm/FaceDetectAlgorithm.cpp Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td id="projectalign" style="padding-left: 0.5em;">
<div id="projectname">CortexRobot
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.13 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="dir_28e1bb8382970ac72e8ae3b23df4a891.html">temp</a></li><li class="navelem"><a class="el" href="dir_7ee3436e08fefa5a3e5de148816e60bf.html">des</a></li><li class="navelem"><a class="el" href="dir_9f521f3c0054d89524661d351ceeeed2.html">CameraTest_nofreev_branch</a></li><li class="navelem"><a class="el" href="dir_11fc880b39daecaf26a43a29a4b0ffd7.html">Algorithm</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="headertitle">
<div class="title">FaceDetectAlgorithm.cpp</div> </div>
</div><!--header-->
<div class="contents">
<a href="_face_detect_algorithm_8cpp.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span> <span class="preprocessor">#include "<a class="code" href="_face_detect_algorithm_8h.html">FaceDetectAlgorithm.h</a>"</span></div><div class="line"><a name="l00002"></a><span class="lineno"> 2</span> <span class="keyword">using namespace </span><a class="code" href="namespacestd.html">std</a>;</div><div class="line"><a name="l00003"></a><span class="lineno"> 3</span> <span class="keyword">using namespace </span><a class="code" href="namespacecv.html">cv</a>;</div><div class="line"><a name="l00004"></a><span class="lineno"> 4</span> </div><div class="line"><a name="l00005"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#ac0be172b2983ad69dbb4f09df4ee882d"> 5</a></span> <a class="code" href="class_face_detect_algorithm.html#ac0be172b2983ad69dbb4f09df4ee882d">FaceDetectAlgorithm::FaceDetectAlgorithm</a>(QObject *parent) : QObject(parent),</div><div class="line"><a name="l00006"></a><span class="lineno"> 6</span>  fisher_detector(this)</div><div class="line"><a name="l00007"></a><span class="lineno"> 7</span> {</div><div class="line"><a name="l00008"></a><span class="lineno"> 8</span>  MyDebug;</div><div class="line"><a name="l00009"></a><span class="lineno"> 9</span>  <a class="code" href="class_face_detect_algorithm.html#a2402774af43118bc1c81832c492d0edf">setEyeCircleColor</a>(Scalar(0, 255, 255));</div><div class="line"><a name="l00010"></a><span class="lineno"> 10</span>  <a class="code" href="class_face_detect_algorithm.html#a1af5c8e516f5f2b821ed4ef26da53adb">setFaceRectColor</a>(Scalar(250, 50, 50));</div><div class="line"><a name="l00011"></a><span class="lineno"> 11</span> }</div><div class="line"><a name="l00012"></a><span class="lineno"> 12</span> </div><div class="line"><a name="l00013"></a><span class="lineno"> 13</span> </div><div class="line"><a name="l00014"></a><span class="lineno"> 14</span> </div><div class="line"><a name="l00015"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a933a23a9fe1b84b0a0968d9abb526c0d"> 15</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#a933a23a9fe1b84b0a0968d9abb526c0d">FaceDetectAlgorithm::drawRect</a>(Rect &rect, <span class="keyword">const</span> Scalar &color, <span class="keywordtype">int</span> thickness, <span class="keywordtype">int</span> linetype)</div><div class="line"><a name="l00016"></a><span class="lineno"> 16</span> {</div><div class="line"><a name="l00017"></a><span class="lineno"> 17</span>  MyDebug;</div><div class="line"><a name="l00018"></a><span class="lineno"> 18</span>  cv::rectangle(this-><a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, rect, color, thickness, linetype);</div><div class="line"><a name="l00019"></a><span class="lineno"> 19</span> }</div><div class="line"><a name="l00020"></a><span class="lineno"> 20</span> </div><div class="line"><a name="l00021"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#aaef97b55f3011a315bb4f544e3bf9ac6"> 21</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#aaef97b55f3011a315bb4f544e3bf9ac6">FaceDetectAlgorithm::drawCircle</a>(Point &point_center, <span class="keywordtype">int</span> radius, <span class="keyword">const</span> Scalar &color, <span class="keywordtype">int</span> thickness, <span class="keywordtype">int</span> linetype)</div><div class="line"><a name="l00022"></a><span class="lineno"> 22</span> {</div><div class="line"><a name="l00023"></a><span class="lineno"> 23</span>  MyDebug;</div><div class="line"><a name="l00024"></a><span class="lineno"> 24</span>  cv::circle(this-><a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, point_center, radius, color, thickness, linetype);</div><div class="line"><a name="l00025"></a><span class="lineno"> 25</span> }</div><div class="line"><a name="l00026"></a><span class="lineno"> 26</span> </div><div class="line"><a name="l00027"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a2dd7def401b83e4d29a3dee19a227c30"> 27</a></span> Rect <a class="code" href="class_face_detect_algorithm.html#a2dd7def401b83e4d29a3dee19a227c30">FaceDetectAlgorithm::drawString</a>(Mat &img, <span class="keywordtype">string</span> text, Point coord, Scalar color, <span class="keywordtype">float</span> fontScale, <span class="keywordtype">int</span> thickness, <span class="keywordtype">int</span> fontFace)</div><div class="line"><a name="l00028"></a><span class="lineno"> 28</span> {</div><div class="line"><a name="l00029"></a><span class="lineno"> 29</span>  MyDebug;</div><div class="line"><a name="l00030"></a><span class="lineno"> 30</span>  <span class="comment">// Get the text size & baseline.</span></div><div class="line"><a name="l00031"></a><span class="lineno"> 31</span>  <span class="keywordtype">int</span> baseline = 0;</div><div class="line"><a name="l00032"></a><span class="lineno"> 32</span>  Size textSize = getTextSize(text, fontFace, fontScale, thickness, &baseline);</div><div class="line"><a name="l00033"></a><span class="lineno"> 33</span>  baseline += thickness;</div><div class="line"><a name="l00034"></a><span class="lineno"> 34</span> </div><div class="line"><a name="l00035"></a><span class="lineno"> 35</span>  <span class="comment">// Adjust the coords for left/right-justified or top/bottom-justified.</span></div><div class="line"><a name="l00036"></a><span class="lineno"> 36</span>  <span class="keywordflow">if</span> (coord.y >= 0) {</div><div class="line"><a name="l00037"></a><span class="lineno"> 37</span>  <span class="comment">// Coordinates are for the top-left corner of the text from the top-left of the image, so move down by one row.</span></div><div class="line"><a name="l00038"></a><span class="lineno"> 38</span>  coord.y += textSize.height;</div><div class="line"><a name="l00039"></a><span class="lineno"> 39</span>  }</div><div class="line"><a name="l00040"></a><span class="lineno"> 40</span>  <span class="keywordflow">else</span> {</div><div class="line"><a name="l00041"></a><span class="lineno"> 41</span>  <span class="comment">// Coordinates are for the bottom-left corner of the text from the bottom-left of the image, so come up from the bottom.</span></div><div class="line"><a name="l00042"></a><span class="lineno"> 42</span>  coord.y += img.rows - baseline + 1;</div><div class="line"><a name="l00043"></a><span class="lineno"> 43</span>  }</div><div class="line"><a name="l00044"></a><span class="lineno"> 44</span>  <span class="comment">// Become right-justified if desired.</span></div><div class="line"><a name="l00045"></a><span class="lineno"> 45</span>  <span class="keywordflow">if</span> (coord.x < 0) {</div><div class="line"><a name="l00046"></a><span class="lineno"> 46</span>  coord.x += img.cols - textSize.width + 1;</div><div class="line"><a name="l00047"></a><span class="lineno"> 47</span>  }</div><div class="line"><a name="l00048"></a><span class="lineno"> 48</span> </div><div class="line"><a name="l00049"></a><span class="lineno"> 49</span>  <span class="comment">// Get the bounding box around the text.</span></div><div class="line"><a name="l00050"></a><span class="lineno"> 50</span>  Rect boundingRect = Rect(coord.x, coord.y - textSize.height, textSize.width, baseline + textSize.height);</div><div class="line"><a name="l00051"></a><span class="lineno"> 51</span> </div><div class="line"><a name="l00052"></a><span class="lineno"> 52</span>  <span class="comment">// Draw anti-aliased text.</span></div><div class="line"><a name="l00053"></a><span class="lineno"> 53</span>  putText(img, text, coord, fontFace, fontScale, color, thickness, CV_AA);</div><div class="line"><a name="l00054"></a><span class="lineno"> 54</span> </div><div class="line"><a name="l00055"></a><span class="lineno"> 55</span>  <span class="comment">// Let the user know how big their text is, in case they want to arrange things.</span></div><div class="line"><a name="l00056"></a><span class="lineno"> 56</span>  <span class="keywordflow">return</span> boundingRect;</div><div class="line"><a name="l00057"></a><span class="lineno"> 57</span> }</div><div class="line"><a name="l00058"></a><span class="lineno"> 58</span> </div><div class="line"><a name="l00059"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a12d8994f5eea57fe54ce731e8a5b1374"> 59</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#a12d8994f5eea57fe54ce731e8a5b1374">FaceDetectAlgorithm::showFaceMarker</a>()</div><div class="line"><a name="l00060"></a><span class="lineno"> 60</span> {</div><div class="line"><a name="l00061"></a><span class="lineno"> 61</span>  MyDebug;</div><div class="line"><a name="l00062"></a><span class="lineno"> 62</span>  <span class="keywordflow">if</span> (!this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aee98ff43d21ca7793f9f2e41f95ba61d">preprocess</a>.<a class="code" href="class_preprocess_face.html#a2466930f9d2bb40eb974e2eff163fcfd">empty</a>())</div><div class="line"><a name="l00063"></a><span class="lineno"> 63</span>  {</div><div class="line"><a name="l00064"></a><span class="lineno"> 64</span>  this-><a class="code" href="class_face_detect_algorithm.html#a933a23a9fe1b84b0a0968d9abb526c0d">drawRect</a>(this-><a class="code" href="class_face_detect_algorithm.html#a1fa6194eb73cf9bd9926a481447b09d5">face_location</a>, this-><a class="code" href="class_face_detect_algorithm.html#a9bcd32ec18b639f2598935c70c4d7760">face_rect_color</a>, 3);</div><div class="line"><a name="l00065"></a><span class="lineno"> 65</span>  }</div><div class="line"><a name="l00066"></a><span class="lineno"> 66</span> }</div><div class="line"><a name="l00067"></a><span class="lineno"> 67</span> </div><div class="line"><a name="l00068"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a5fd2a744896e3b28a2ef7b1009e156e3"> 68</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#a5fd2a744896e3b28a2ef7b1009e156e3">FaceDetectAlgorithm::showEyesMarker</a>()</div><div class="line"><a name="l00069"></a><span class="lineno"> 69</span> {</div><div class="line"><a name="l00070"></a><span class="lineno"> 70</span>  MyDebug;</div><div class="line"><a name="l00071"></a><span class="lineno"> 71</span>  <span class="keywordflow">if</span> (!this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aee98ff43d21ca7793f9f2e41f95ba61d">preprocess</a>.<a class="code" href="class_preprocess_face.html#a2466930f9d2bb40eb974e2eff163fcfd">empty</a>())</div><div class="line"><a name="l00072"></a><span class="lineno"> 72</span>  {</div><div class="line"><a name="l00073"></a><span class="lineno"> 73</span>  Point eye_left_tmp = Point(<a class="code" href="class_face_detect_algorithm.html#a1fa6194eb73cf9bd9926a481447b09d5">face_location</a>.x + <a class="code" href="class_face_detect_algorithm.html#a2844c14c1d0382e99bf61406a7be5d1a">eye_left</a>.x, <a class="code" href="class_face_detect_algorithm.html#a1fa6194eb73cf9bd9926a481447b09d5">face_location</a>.y + <a class="code" href="class_face_detect_algorithm.html#a2844c14c1d0382e99bf61406a7be5d1a">eye_left</a>.y);</div><div class="line"><a name="l00074"></a><span class="lineno"> 74</span>  Point eye_right_tmp = Point(<a class="code" href="class_face_detect_algorithm.html#a1fa6194eb73cf9bd9926a481447b09d5">face_location</a>.x + <a class="code" href="class_face_detect_algorithm.html#a2734f9d2a35b7069b0439a12cb65432f">eye_right</a>.x, <a class="code" href="class_face_detect_algorithm.html#a1fa6194eb73cf9bd9926a481447b09d5">face_location</a>.y + <a class="code" href="class_face_detect_algorithm.html#a2734f9d2a35b7069b0439a12cb65432f">eye_right</a>.y);</div><div class="line"><a name="l00075"></a><span class="lineno"> 75</span>  <span class="keywordflow">if</span> (this-><a class="code" href="class_face_detect_algorithm.html#a2844c14c1d0382e99bf61406a7be5d1a">eye_left</a>.x > 0)</div><div class="line"><a name="l00076"></a><span class="lineno"> 76</span>  this-><a class="code" href="class_face_detect_algorithm.html#aaef97b55f3011a315bb4f544e3bf9ac6">drawCircle</a>(eye_left_tmp, 6, this-><a class="code" href="class_face_detect_algorithm.html#aead21cb252c0fd97454a9c2e99b7a4b8">eye_circle_color</a>, 1, CV_AA);</div><div class="line"><a name="l00077"></a><span class="lineno"> 77</span>  <span class="keywordflow">if</span> (this-><a class="code" href="class_face_detect_algorithm.html#a2734f9d2a35b7069b0439a12cb65432f">eye_right</a>.x > 0)</div><div class="line"><a name="l00078"></a><span class="lineno"> 78</span>  this-><a class="code" href="class_face_detect_algorithm.html#aaef97b55f3011a315bb4f544e3bf9ac6">drawCircle</a>(eye_right_tmp, 6, this-><a class="code" href="class_face_detect_algorithm.html#aead21cb252c0fd97454a9c2e99b7a4b8">eye_circle_color</a>, 1, CV_AA);</div><div class="line"><a name="l00079"></a><span class="lineno"> 79</span>  }</div><div class="line"><a name="l00080"></a><span class="lineno"> 80</span> }</div><div class="line"><a name="l00081"></a><span class="lineno"> 81</span> </div><div class="line"><a name="l00082"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#ae151eb8e68476b58ce58c9536dcc1c15"> 82</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#ae151eb8e68476b58ce58c9536dcc1c15">FaceDetectAlgorithm::showConfidenceRatio</a>()</div><div class="line"><a name="l00083"></a><span class="lineno"> 83</span> {</div><div class="line"><a name="l00084"></a><span class="lineno"> 84</span>  MyDebug;</div><div class="line"><a name="l00085"></a><span class="lineno"> 85</span>  <span class="comment">// Show the confidence rating for the recognition in the mid-top of the display.</span></div><div class="line"><a name="l00086"></a><span class="lineno"> 86</span>  <span class="keywordtype">int</span> faceWidth = <a class="code" href="namespace_configuration.html#adb7fd1f86bf07d56bcca190c05847582">Configuration::DESIRED_FACE_WIDTH</a>;</div><div class="line"><a name="l00087"></a><span class="lineno"> 87</span>  <span class="keywordtype">int</span> faceHeight = faceWidth;</div><div class="line"><a name="l00088"></a><span class="lineno"> 88</span>  <span class="keywordtype">int</span> cx = (<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>.cols - faceWidth) / 2;</div><div class="line"><a name="l00089"></a><span class="lineno"> 89</span>  Point ptBottomRight = Point(cx - 5, <a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a> + faceHeight);</div><div class="line"><a name="l00090"></a><span class="lineno"> 90</span>  Point ptTopLeft = Point(cx - 15, <a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a>);</div><div class="line"><a name="l00091"></a><span class="lineno"> 91</span>  <span class="comment">// Draw a gray line showing the threshold for an "unknown" person.</span></div><div class="line"><a name="l00092"></a><span class="lineno"> 92</span>  Point ptThreshold = Point(ptTopLeft.x, ptBottomRight.y - (1.0 - <a class="code" href="namespace_configuration.html#aabd7b608d1256e4e08b15ec0e35c4483">Configuration::UNKNOWN_PERSON_THRESHOLD</a>) * faceHeight);</div><div class="line"><a name="l00093"></a><span class="lineno"> 93</span>  rectangle(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, ptThreshold, Point(ptBottomRight.x, ptThreshold.y), CV_RGB(200, 200, 200), 1, CV_AA);</div><div class="line"><a name="l00094"></a><span class="lineno"> 94</span>  <span class="comment">// Crop the confidence rating between 0.0 to 1.0, to show in the bar.</span></div><div class="line"><a name="l00095"></a><span class="lineno"> 95</span>  <span class="comment">//double confidenceRatio = 1.0 - min(max(similarity, 0.0), 1.0);</span></div><div class="line"><a name="l00096"></a><span class="lineno"> 96</span>  Point ptConfidence = Point(ptTopLeft.x, ptBottomRight.y - this->fisher_detector.getConfidence() * faceHeight);</div><div class="line"><a name="l00097"></a><span class="lineno"> 97</span>  <span class="comment">// Show the light-blue confidence bar.</span></div><div class="line"><a name="l00098"></a><span class="lineno"> 98</span>  rectangle(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, ptConfidence, ptBottomRight, CV_RGB(0, 255, 255), CV_FILLED, CV_AA);</div><div class="line"><a name="l00099"></a><span class="lineno"> 99</span>  <span class="comment">// Show the gray border of the bar.</span></div><div class="line"><a name="l00100"></a><span class="lineno"> 100</span>  rectangle(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, ptTopLeft, ptBottomRight, CV_RGB(200, 200, 200), 1, CV_AA);</div><div class="line"><a name="l00101"></a><span class="lineno"> 101</span> }</div><div class="line"><a name="l00102"></a><span class="lineno"> 102</span> </div><div class="line"><a name="l00103"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a2a2ee1334b59a677cbb1ae1d97006ca5"> 103</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#a2a2ee1334b59a677cbb1ae1d97006ca5">FaceDetectAlgorithm::showPreprocessFace</a>()</div><div class="line"><a name="l00104"></a><span class="lineno"> 104</span> {</div><div class="line"><a name="l00105"></a><span class="lineno"> 105</span>  MyDebug;</div><div class="line"><a name="l00106"></a><span class="lineno"> 106</span>  <span class="keywordtype">int</span> faceWidth = <a class="code" href="namespace_configuration.html#adb7fd1f86bf07d56bcca190c05847582">Configuration::DESIRED_FACE_WIDTH</a>;</div><div class="line"><a name="l00107"></a><span class="lineno"> 107</span>  <span class="keywordtype">int</span> faceHeight = faceWidth;</div><div class="line"><a name="l00108"></a><span class="lineno"> 108</span>  <span class="comment">// Show the current preprocessed face in the top-center of the display.</span></div><div class="line"><a name="l00109"></a><span class="lineno"> 109</span>  <span class="keywordtype">int</span> cx = (<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>.cols - faceWidth) / 2;</div><div class="line"><a name="l00110"></a><span class="lineno"> 110</span>  <span class="keywordflow">if</span> (!this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aee98ff43d21ca7793f9f2e41f95ba61d">preprocess</a>.<a class="code" href="class_preprocess_face.html#a2466930f9d2bb40eb974e2eff163fcfd">empty</a>())</div><div class="line"><a name="l00111"></a><span class="lineno"> 111</span>  {</div><div class="line"><a name="l00112"></a><span class="lineno"> 112</span> </div><div class="line"><a name="l00113"></a><span class="lineno"> 113</span>  <span class="keywordflow">if</span> (!this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aee98ff43d21ca7793f9f2e41f95ba61d">preprocess</a>.<a class="code" href="class_preprocess_face.html#a94616b0b0118bea878f2d1ef6651fd50">at</a>(0).empty()) {</div><div class="line"><a name="l00114"></a><span class="lineno"> 114</span>  <span class="comment">// Get a BGR version of the face, since the output is BGR color.</span></div><div class="line"><a name="l00115"></a><span class="lineno"> 115</span>  Mat srcBGR = Mat(this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aee98ff43d21ca7793f9f2e41f95ba61d">preprocess</a>.<a class="code" href="class_preprocess_face.html#a94616b0b0118bea878f2d1ef6651fd50">at</a>(0).size(), CV_8UC3);</div><div class="line"><a name="l00116"></a><span class="lineno"> 116</span>  cvtColor(this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aee98ff43d21ca7793f9f2e41f95ba61d">preprocess</a>.<a class="code" href="class_preprocess_face.html#a94616b0b0118bea878f2d1ef6651fd50">at</a>(0), srcBGR, CV_GRAY2BGR);</div><div class="line"><a name="l00117"></a><span class="lineno"> 117</span>  <span class="comment">// Get the destination ROI (and make sure it is within the image!).</span></div><div class="line"><a name="l00118"></a><span class="lineno"> 118</span>  <span class="comment">//min(m_gui_faces_top + i * faceHeight, displayedFrame.rows - faceHeight);</span></div><div class="line"><a name="l00119"></a><span class="lineno"> 119</span>  Rect dstRC = Rect(cx, <a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a>, faceWidth, faceHeight);</div><div class="line"><a name="l00120"></a><span class="lineno"> 120</span>  Mat dstROI = <a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>(dstRC);</div><div class="line"><a name="l00121"></a><span class="lineno"> 121</span>  <span class="comment">// Copy the pixels from src to dst.</span></div><div class="line"><a name="l00122"></a><span class="lineno"> 122</span>  srcBGR.copyTo(dstROI);</div><div class="line"><a name="l00123"></a><span class="lineno"> 123</span>  }</div><div class="line"><a name="l00124"></a><span class="lineno"> 124</span>  }</div><div class="line"><a name="l00125"></a><span class="lineno"> 125</span>  <span class="comment">// Draw an anti-aliased border around the face, even if it is not shown.</span></div><div class="line"><a name="l00126"></a><span class="lineno"> 126</span>  rectangle(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, Rect(cx - 1, <a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a> - 1, faceWidth + 2, faceHeight + 2), CV_RGB(200, 200, 200), 1, CV_AA);</div><div class="line"><a name="l00127"></a><span class="lineno"> 127</span> </div><div class="line"><a name="l00128"></a><span class="lineno"> 128</span> }</div><div class="line"><a name="l00129"></a><span class="lineno"> 129</span> </div><div class="line"><a name="l00130"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a00cd48891549b3fbc8587cd33fc5020b"> 130</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#a00cd48891549b3fbc8587cd33fc5020b">FaceDetectAlgorithm::showRecentFaces</a>()</div><div class="line"><a name="l00131"></a><span class="lineno"> 131</span> {</div><div class="line"><a name="l00132"></a><span class="lineno"> 132</span>  MyDebug;</div><div class="line"><a name="l00133"></a><span class="lineno"> 133</span>  <span class="keywordtype">int</span> faceWidth = <a class="code" href="namespace_configuration.html#adb7fd1f86bf07d56bcca190c05847582">Configuration::DESIRED_FACE_WIDTH</a>;</div><div class="line"><a name="l00134"></a><span class="lineno"> 134</span>  <span class="keywordtype">int</span> faceHeight = faceWidth;</div><div class="line"><a name="l00135"></a><span class="lineno"> 135</span>  <span class="comment">// Show the most recent face for each of the collected people, on the right side of the display.</span></div><div class="line"><a name="l00136"></a><span class="lineno"> 136</span>  <span class="keywordtype">int</span> m_gui_faces_left = <a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>.cols - <a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a> - faceWidth;</div><div class="line"><a name="l00137"></a><span class="lineno"> 137</span>  <span class="keywordtype">int</span> m_gui_faces_top = <a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a>;</div><div class="line"><a name="l00138"></a><span class="lineno"> 138</span>  <span class="comment">// Highlight the person being collected, using a red rectangle around their face.</span></div><div class="line"><a name="l00139"></a><span class="lineno"> 139</span>  <span class="keywordflow">if</span> (this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a5b359dd6ea6f4671fe5af7f34cbcc012">fisher_mode</a> == <a class="code" href="_common_8h.html#a13bce11aca45a14b793b12be56a00f16a154d714d5660ce2f2caf4376858f35c0">MODE_COLLECT_FACES</a>) {</div><div class="line"><a name="l00140"></a><span class="lineno"> 140</span>  <span class="keywordflow">if</span> (this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a6069e77ca4b911295f96b059c86916f0">getPersionId</a>() >= 0 && this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a6069e77ca4b911295f96b059c86916f0">getPersionId</a>() < this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a32e3a8c4908862fb3722732d82d73682">getNumPersions</a>())</div><div class="line"><a name="l00141"></a><span class="lineno"> 141</span>  {</div><div class="line"><a name="l00142"></a><span class="lineno"> 142</span>  <span class="keywordtype">int</span> y = min(m_gui_faces_top + this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a6069e77ca4b911295f96b059c86916f0">getPersionId</a>() * faceHeight, <a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>.rows - faceHeight);</div><div class="line"><a name="l00143"></a><span class="lineno"> 143</span>  Rect rc = Rect(m_gui_faces_left, y, faceWidth, faceHeight);</div><div class="line"><a name="l00144"></a><span class="lineno"> 144</span>  rectangle(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, rc, CV_RGB(255, 0, 0), 3, CV_AA);</div><div class="line"><a name="l00145"></a><span class="lineno"> 145</span>  }</div><div class="line"><a name="l00146"></a><span class="lineno"> 146</span>  }</div><div class="line"><a name="l00147"></a><span class="lineno"> 147</span> </div><div class="line"><a name="l00148"></a><span class="lineno"> 148</span>  <span class="comment">// Highlight the person that has been recognized, using a green rectangle around their face.</span></div><div class="line"><a name="l00149"></a><span class="lineno"> 149</span>  <span class="keywordtype">int</span> identity = this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aa98ba6019ca7c1a37d9fe2ad0a10978d">getIdentity</a>();</div><div class="line"><a name="l00150"></a><span class="lineno"> 150</span>  <span class="keywordflow">if</span> (identity >= 0 && identity < 1000) {</div><div class="line"><a name="l00151"></a><span class="lineno"> 151</span>  <span class="keywordtype">int</span> y = min(m_gui_faces_top + identity * faceHeight, <a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>.rows - faceHeight);</div><div class="line"><a name="l00152"></a><span class="lineno"> 152</span>  Rect rc = Rect(m_gui_faces_left, y, faceWidth, faceHeight);</div><div class="line"><a name="l00153"></a><span class="lineno"> 153</span>  rectangle(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, rc, CV_RGB(0, 255, 0), 3, CV_AA);</div><div class="line"><a name="l00154"></a><span class="lineno"> 154</span>  }</div><div class="line"><a name="l00155"></a><span class="lineno"> 155</span> }</div><div class="line"><a name="l00156"></a><span class="lineno"> 156</span> </div><div class="line"><a name="l00157"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a019f7d08e7bc24239808946c33d08ebe"> 157</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#a019f7d08e7bc24239808946c33d08ebe">FaceDetectAlgorithm::showDebugData</a>(Mat &<a class="code" href="class_face_detect_algorithm.html#a684f7c8e0a48ce767f887b292911432c">src_image</a>)</div><div class="line"><a name="l00158"></a><span class="lineno"> 158</span> {</div><div class="line"><a name="l00159"></a><span class="lineno"> 159</span>  MyDebug;</div><div class="line"><a name="l00160"></a><span class="lineno"> 160</span>  <span class="keywordflow">if</span> (!this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aee98ff43d21ca7793f9f2e41f95ba61d">preprocess</a>.<a class="code" href="class_preprocess_face.html#a2466930f9d2bb40eb974e2eff163fcfd">empty</a>())</div><div class="line"><a name="l00161"></a><span class="lineno"> 161</span>  {</div><div class="line"><a name="l00162"></a><span class="lineno"> 162</span>  <span class="keywordflow">if</span> (this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#ab7620661e0e1175c5b418716f187a746">fisher_debug</a>)</div><div class="line"><a name="l00163"></a><span class="lineno"> 163</span>  {</div><div class="line"><a name="l00164"></a><span class="lineno"> 164</span>  Mat face;</div><div class="line"><a name="l00165"></a><span class="lineno"> 165</span>  <span class="keywordflow">if</span> (this-><a class="code" href="class_face_detect_algorithm.html#a1fa6194eb73cf9bd9926a481447b09d5">face_location</a>.width > 0)</div><div class="line"><a name="l00166"></a><span class="lineno"> 166</span>  {</div><div class="line"><a name="l00167"></a><span class="lineno"> 167</span>  face = <a class="code" href="class_face_detect_algorithm.html#a684f7c8e0a48ce767f887b292911432c">src_image</a>(this-><a class="code" href="class_face_detect_algorithm.html#a1fa6194eb73cf9bd9926a481447b09d5">face_location</a>);</div><div class="line"><a name="l00168"></a><span class="lineno"> 168</span>  <span class="keywordflow">if</span> (this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aee98ff43d21ca7793f9f2e41f95ba61d">preprocess</a>.<a class="code" href="class_preprocess_face.html#a02f44831902ebc0489ae8c890639b2a2">searchedLeftEye</a>.at(0).width > 0 && this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aee98ff43d21ca7793f9f2e41f95ba61d">preprocess</a>.<a class="code" href="class_preprocess_face.html#a9f7771b65c57d2294e0ee258eaaa15e3">searchedRightEye</a>.at(0).width > 0)</div><div class="line"><a name="l00169"></a><span class="lineno"> 169</span>  {</div><div class="line"><a name="l00170"></a><span class="lineno"> 170</span>  Mat topLeftOfFace = face(this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aee98ff43d21ca7793f9f2e41f95ba61d">preprocess</a>.<a class="code" href="class_preprocess_face.html#a02f44831902ebc0489ae8c890639b2a2">searchedLeftEye</a>.at(0));</div><div class="line"><a name="l00171"></a><span class="lineno"> 171</span>  Mat topRightOfFace = face(this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aee98ff43d21ca7793f9f2e41f95ba61d">preprocess</a>.<a class="code" href="class_preprocess_face.html#a9f7771b65c57d2294e0ee258eaaa15e3">searchedRightEye</a>.at(0));</div><div class="line"><a name="l00172"></a><span class="lineno"> 172</span>  imshow(<span class="stringliteral">"topLeftOfFace"</span>, topLeftOfFace);</div><div class="line"><a name="l00173"></a><span class="lineno"> 173</span>  imshow(<span class="stringliteral">"topRightOfFace"</span>, topRightOfFace);</div><div class="line"><a name="l00174"></a><span class="lineno"> 174</span>  waitKey(0);</div><div class="line"><a name="l00175"></a><span class="lineno"> 175</span>  }</div><div class="line"><a name="l00176"></a><span class="lineno"> 176</span>  }</div><div class="line"><a name="l00177"></a><span class="lineno"> 177</span> </div><div class="line"><a name="l00178"></a><span class="lineno"> 178</span>  <span class="keywordflow">if</span> (!this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a0bee9594a637922f641d61ad7e448549">model</a>.<a class="code" href="class_fisher_model_entity.html#af6d16b989d4151ff521f80aa08b6d488">data</a>.empty())</div><div class="line"><a name="l00179"></a><span class="lineno"> 179</span>  this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aedfd142d604b9b6f2bc2e5acc2f2b1a9">showTrainingDebugData</a>();</div><div class="line"><a name="l00180"></a><span class="lineno"> 180</span>  }</div><div class="line"><a name="l00181"></a><span class="lineno"> 181</span>  }</div><div class="line"><a name="l00182"></a><span class="lineno"> 182</span> }</div><div class="line"><a name="l00183"></a><span class="lineno"> 183</span> </div><div class="line"><a name="l00184"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#aa6c039b1d5e082c44e438280d2583246"> 184</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#aa6c039b1d5e082c44e438280d2583246">FaceDetectAlgorithm::showLandMarkPoint</a>()</div><div class="line"><a name="l00185"></a><span class="lineno"> 185</span> {</div><div class="line"><a name="l00186"></a><span class="lineno"> 186</span>  MyDebug;</div><div class="line"><a name="l00187"></a><span class="lineno"> 187</span>  <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> <a class="code" href="process__1_8m.html#a8c4e28b0ee15a1005df90b45f3b82ea8">i</a> = 0; <a class="code" href="process__1_8m.html#a8c4e28b0ee15a1005df90b45f3b82ea8">i</a> < <a class="code" href="class_face_detect_algorithm.html#a8a2dccb8f7f9540074872a7d441e1168">landmark_points</a>.size(); ++<a class="code" href="process__1_8m.html#a8c4e28b0ee15a1005df90b45f3b82ea8">i</a>)</div><div class="line"><a name="l00188"></a><span class="lineno"> 188</span>  {</div><div class="line"><a name="l00189"></a><span class="lineno"> 189</span>  cv::circle(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, <a class="code" href="class_face_detect_algorithm.html#a8a2dccb8f7f9540074872a7d441e1168">landmark_points</a>.at(<a class="code" href="process__1_8m.html#a8c4e28b0ee15a1005df90b45f3b82ea8">i</a>), 3, cv::Scalar(0, 255, 0), FILLED);</div><div class="line"><a name="l00190"></a><span class="lineno"> 190</span>  }</div><div class="line"><a name="l00191"></a><span class="lineno"> 191</span> }</div><div class="line"><a name="l00192"></a><span class="lineno"> 192</span> </div><div class="line"><a name="l00193"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a4c9102e71cc835b0ceb058fcff46c342"> 193</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#a4c9102e71cc835b0ceb058fcff46c342">FaceDetectAlgorithm::showHelp</a>()</div><div class="line"><a name="l00194"></a><span class="lineno"> 194</span> {</div><div class="line"><a name="l00195"></a><span class="lineno"> 195</span>  MyDebug;</div><div class="line"><a name="l00196"></a><span class="lineno"> 196</span>  <span class="comment">// Show the help, while also showing the number of collected faces. Since we also collect mirrored faces, we should just</span></div><div class="line"><a name="l00197"></a><span class="lineno"> 197</span>  <span class="comment">// tell the user how many faces they think we saved (ignoring the mirrored faces), hence divide by 2.</span></div><div class="line"><a name="l00198"></a><span class="lineno"> 198</span>  <span class="keywordtype">string</span> help;</div><div class="line"><a name="l00199"></a><span class="lineno"> 199</span>  <span class="keywordflow">if</span> (this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a5b359dd6ea6f4671fe5af7f34cbcc012">fisher_mode</a> == <a class="code" href="_common_8h.html#a13bce11aca45a14b793b12be56a00f16af2c99680641133a2b366c25bb6719df3">MODE_DETECTION</a>)</div><div class="line"><a name="l00200"></a><span class="lineno"> 200</span>  help = <span class="stringliteral">"Click [Add Person] when ready to collect faces."</span>;</div><div class="line"><a name="l00201"></a><span class="lineno"> 201</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a5b359dd6ea6f4671fe5af7f34cbcc012">fisher_mode</a> == <a class="code" href="_common_8h.html#a13bce11aca45a14b793b12be56a00f16a154d714d5660ce2f2caf4376858f35c0">MODE_COLLECT_FACES</a>)</div><div class="line"><a name="l00202"></a><span class="lineno"> 202</span>  help = <span class="stringliteral">"Current collect faces num is: "</span> + <a class="code" href="class_common.html#ab81ddd95b5858e34b620510cc45e9baa">Common::toString</a>(this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a2c8453e74e29ab69bd16fb8a36a5a41a">getCollectionNum</a>()) +</div><div class="line"><a name="l00203"></a><span class="lineno"> 203</span>  <span class="stringliteral">" faces of "</span> + <a class="code" href="class_common.html#ab81ddd95b5858e34b620510cc45e9baa">Common::toString</a>(this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a32e3a8c4908862fb3722732d82d73682">getNumPersions</a>()) + <span class="stringliteral">" people. Current people ID: "</span> +</div><div class="line"><a name="l00204"></a><span class="lineno"> 204</span>  <a class="code" href="class_common.html#ab81ddd95b5858e34b620510cc45e9baa">Common::toString</a>(this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a6069e77ca4b911295f96b059c86916f0">getPersionId</a>());</div><div class="line"><a name="l00205"></a><span class="lineno"> 205</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a5b359dd6ea6f4671fe5af7f34cbcc012">fisher_mode</a>== <a class="code" href="_common_8h.html#a13bce11aca45a14b793b12be56a00f16a9b5633a34baeeefaa0ce3f17936be149">MODE_TRAINING</a>)</div><div class="line"><a name="l00206"></a><span class="lineno"> 206</span>  help = <span class="stringliteral">"Please wait while your "</span> + <a class="code" href="class_common.html#ab81ddd95b5858e34b620510cc45e9baa">Common::toString</a>(this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#aee98ff43d21ca7793f9f2e41f95ba61d">preprocess</a>.<a class="code" href="class_preprocess_face.html#af0b1d20e88d77e0ef8478fd6a9dce0d7">size</a>() / 2) + <span class="stringliteral">" faces of "</span> + <a class="code" href="class_common.html#ab81ddd95b5858e34b620510cc45e9baa">Common::toString</a>(this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a32e3a8c4908862fb3722732d82d73682">getNumPersions</a>()) + <span class="stringliteral">" people builds."</span>;</div><div class="line"><a name="l00207"></a><span class="lineno"> 207</span>  <span class="keywordflow">else</span> <span class="keywordflow">if</span> (this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a5b359dd6ea6f4671fe5af7f34cbcc012">fisher_mode</a> == <a class="code" href="_common_8h.html#a13bce11aca45a14b793b12be56a00f16a4c6039abaf1081121f56eefabbad5eb4">MODE_RECOGNITION</a>)</div><div class="line"><a name="l00208"></a><span class="lineno"> 208</span>  help = <span class="stringliteral">"Click people on the right to add more faces to them, or [Add Person] for someone new."</span>;</div><div class="line"><a name="l00209"></a><span class="lineno"> 209</span>  <span class="keywordflow">if</span> (help.length() > 0)</div><div class="line"><a name="l00210"></a><span class="lineno"> 210</span>  {</div><div class="line"><a name="l00211"></a><span class="lineno"> 211</span>  <span class="comment">// Draw it with a black background and then again with a white foreground.</span></div><div class="line"><a name="l00212"></a><span class="lineno"> 212</span>  <span class="comment">// Since BORDER may be 0 and we need a negative position, subtract 2 from the border so it is always negative.</span></div><div class="line"><a name="l00213"></a><span class="lineno"> 213</span>  <span class="keywordtype">float</span> txtSize = 0.4;</div><div class="line"><a name="l00214"></a><span class="lineno"> 214</span>  <a class="code" href="class_face_detect_algorithm.html#a2dd7def401b83e4d29a3dee19a227c30">drawString</a>(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, help, Point(<a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a>, -<a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a> - 2), CV_RGB(0, 0, 0), txtSize); <span class="comment">// Black shadow.</span></div><div class="line"><a name="l00215"></a><span class="lineno"> 215</span>  <a class="code" href="class_face_detect_algorithm.html#a66be266c9ff83e6eb8026265610a3437">rcHelp</a> = <a class="code" href="class_face_detect_algorithm.html#a2dd7def401b83e4d29a3dee19a227c30">drawString</a>(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, help, Point(<a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a> + 1, -<a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a> - 1), CV_RGB(255, 255, 255), txtSize); <span class="comment">// White text.</span></div><div class="line"><a name="l00216"></a><span class="lineno"> 216</span>  }</div><div class="line"><a name="l00217"></a><span class="lineno"> 217</span> }</div><div class="line"><a name="l00218"></a><span class="lineno"> 218</span> </div><div class="line"><a name="l00219"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a6ea81eaab10f64cfc354b0e1746746d4"> 219</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#a6ea81eaab10f64cfc354b0e1746746d4">FaceDetectAlgorithm::showCurrentMode</a>()</div><div class="line"><a name="l00220"></a><span class="lineno"> 220</span> {</div><div class="line"><a name="l00221"></a><span class="lineno"> 221</span>  MyDebug;</div><div class="line"><a name="l00222"></a><span class="lineno"> 222</span>  <span class="comment">// Show the current mode.</span></div><div class="line"><a name="l00223"></a><span class="lineno"> 223</span>  <span class="keywordflow">if</span> (this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a5b359dd6ea6f4671fe5af7f34cbcc012">fisher_mode</a> >= 0 && this->fisher_detector.fisher_mode < <a class="code" href="_common_8h.html#a13bce11aca45a14b793b12be56a00f16a406ca8d89d280d3561c76fead32d5aa5">MODE_END</a>)</div><div class="line"><a name="l00224"></a><span class="lineno"> 224</span>  {</div><div class="line"><a name="l00225"></a><span class="lineno"> 225</span>  <span class="keywordtype">string</span> modeStr = <span class="stringliteral">"MODE: "</span> + string(<a class="code" href="class_common.html#ab7f5af0f1add62eb22f6f9e04b9d9efa">Common::MODE_NAME</a>.at(this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a5b359dd6ea6f4671fe5af7f34cbcc012">fisher_mode</a>));</div><div class="line"><a name="l00226"></a><span class="lineno"> 226</span>  <a class="code" href="class_face_detect_algorithm.html#a2dd7def401b83e4d29a3dee19a227c30">drawString</a>(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, modeStr, Point(<a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a>, -<a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a> - 2 - <a class="code" href="class_face_detect_algorithm.html#a66be266c9ff83e6eb8026265610a3437">rcHelp</a>.height), CV_RGB(0, 0, 0)); <span class="comment">// Black shadow</span></div><div class="line"><a name="l00227"></a><span class="lineno"> 227</span>  <a class="code" href="class_face_detect_algorithm.html#a2dd7def401b83e4d29a3dee19a227c30">drawString</a>(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, modeStr, Point(<a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a> + 1, -<a class="code" href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a> - 1 - <a class="code" href="class_face_detect_algorithm.html#a66be266c9ff83e6eb8026265610a3437">rcHelp</a>.height), CV_RGB(0, 255, 0)); <span class="comment">// Green text</span></div><div class="line"><a name="l00228"></a><span class="lineno"> 228</span>  }</div><div class="line"><a name="l00229"></a><span class="lineno"> 229</span> }</div><div class="line"><a name="l00230"></a><span class="lineno"> 230</span> </div><div class="line"><a name="l00231"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a2402774af43118bc1c81832c492d0edf"> 231</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#a2402774af43118bc1c81832c492d0edf">FaceDetectAlgorithm::setEyeCircleColor</a>(<span class="keyword">const</span> Scalar &color)</div><div class="line"><a name="l00232"></a><span class="lineno"> 232</span> {</div><div class="line"><a name="l00233"></a><span class="lineno"> 233</span>  MyDebug;</div><div class="line"><a name="l00234"></a><span class="lineno"> 234</span>  this-><a class="code" href="class_face_detect_algorithm.html#aead21cb252c0fd97454a9c2e99b7a4b8">eye_circle_color</a> = color;</div><div class="line"><a name="l00235"></a><span class="lineno"> 235</span> }</div><div class="line"><a name="l00236"></a><span class="lineno"> 236</span> </div><div class="line"><a name="l00237"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a1af5c8e516f5f2b821ed4ef26da53adb"> 237</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#a1af5c8e516f5f2b821ed4ef26da53adb">FaceDetectAlgorithm::setFaceRectColor</a>(<span class="keyword">const</span> Scalar &color)</div><div class="line"><a name="l00238"></a><span class="lineno"> 238</span> {</div><div class="line"><a name="l00239"></a><span class="lineno"> 239</span>  MyDebug;</div><div class="line"><a name="l00240"></a><span class="lineno"> 240</span>  this-><a class="code" href="class_face_detect_algorithm.html#a9bcd32ec18b639f2598935c70c4d7760">face_rect_color</a> = color;</div><div class="line"><a name="l00241"></a><span class="lineno"> 241</span> }</div><div class="line"><a name="l00242"></a><span class="lineno"> 242</span> </div><div class="line"><a name="l00243"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#aa88289befbb9bece31e4c1bd8e1b82c0"> 243</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#aa88289befbb9bece31e4c1bd8e1b82c0">FaceDetectAlgorithm::setGUIShowRect</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> &width, <span class="keyword">const</span> <span class="keywordtype">int</span> &height)</div><div class="line"><a name="l00244"></a><span class="lineno"> 244</span> {</div><div class="line"><a name="l00245"></a><span class="lineno"> 245</span>  this-><a class="code" href="class_face_detect_algorithm.html#a750758d7a4c23837f3d6400e6254d956">gui_show_width</a> = width;</div><div class="line"><a name="l00246"></a><span class="lineno"> 246</span>  this-><a class="code" href="class_face_detect_algorithm.html#a8de13a75ed483c91e701dd64b88656d5">gui_show_height</a> = height;</div><div class="line"><a name="l00247"></a><span class="lineno"> 247</span> }</div><div class="line"><a name="l00248"></a><span class="lineno"> 248</span> </div><div class="line"><a name="l00255"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a0e55749daeb0c8f250ce3be15c4c5fb8"> 255</a></span> Rect <a class="code" href="class_face_detect_algorithm.html#a0e55749daeb0c8f250ce3be15c4c5fb8">FaceDetectAlgorithm::getShowRect</a>(<span class="keyword">const</span> Mat &<a class="code" href="class_face_detect_algorithm.html#a684f7c8e0a48ce767f887b292911432c">src_image</a>)</div><div class="line"><a name="l00256"></a><span class="lineno"> 256</span> {</div><div class="line"><a name="l00257"></a><span class="lineno"> 257</span>  MyDebug;</div><div class="line"><a name="l00258"></a><span class="lineno"> 258</span>  <span class="keywordtype">double</span> gui_wh_ratio, img_wh_ratio;</div><div class="line"><a name="l00259"></a><span class="lineno"> 259</span>  Rect ret;</div><div class="line"><a name="l00260"></a><span class="lineno"> 260</span>  gui_wh_ratio = (double)this-><a class="code" href="class_face_detect_algorithm.html#a750758d7a4c23837f3d6400e6254d956">gui_show_width</a> / (<span class="keywordtype">double</span>)this-><a class="code" href="class_face_detect_algorithm.html#a8de13a75ed483c91e701dd64b88656d5">gui_show_height</a>;</div><div class="line"><a name="l00261"></a><span class="lineno"> 261</span>  img_wh_ratio = (double)src_image.size().width / (double)src_image.size().height;</div><div class="line"><a name="l00262"></a><span class="lineno"> 262</span>  <span class="keywordflow">if</span> (gui_wh_ratio > img_wh_ratio)</div><div class="line"><a name="l00263"></a><span class="lineno"> 263</span>  {</div><div class="line"><a name="l00264"></a><span class="lineno"> 264</span>  ret.width = src_image.size().width;</div><div class="line"><a name="l00265"></a><span class="lineno"> 265</span>  ret.height = (double)(((<span class="keywordtype">double</span>)ret.width / (<span class="keywordtype">double</span>)<a class="code" href="class_face_detect_algorithm.html#a750758d7a4c23837f3d6400e6254d956">gui_show_width</a>) * (double)<a class="code" href="class_face_detect_algorithm.html#a8de13a75ed483c91e701dd64b88656d5">gui_show_height</a>);</div><div class="line"><a name="l00266"></a><span class="lineno"> 266</span>  ret.x = 0;</div><div class="line"><a name="l00267"></a><span class="lineno"> 267</span>  ret.y = (int)floor(((<span class="keywordtype">double</span>)src_image.size().height - (double)ret.height) / 2.0);</div><div class="line"><a name="l00268"></a><span class="lineno"> 268</span>  }</div><div class="line"><a name="l00269"></a><span class="lineno"> 269</span>  <span class="keywordflow">else</span></div><div class="line"><a name="l00270"></a><span class="lineno"> 270</span>  {</div><div class="line"><a name="l00271"></a><span class="lineno"> 271</span>  ret.height = src_image.size().height;</div><div class="line"><a name="l00272"></a><span class="lineno"> 272</span>  ret.width = (int)(((<span class="keywordtype">double</span>)ret.height / (<span class="keywordtype">double</span>)<a class="code" href="class_face_detect_algorithm.html#a8de13a75ed483c91e701dd64b88656d5">gui_show_height</a>) * (double)<a class="code" href="class_face_detect_algorithm.html#a750758d7a4c23837f3d6400e6254d956">gui_show_width</a>);</div><div class="line"><a name="l00273"></a><span class="lineno"> 273</span> </div><div class="line"><a name="l00274"></a><span class="lineno"> 274</span>  ret.x = (int)floor(((<span class="keywordtype">double</span>)src_image.size().width - (double)ret.width) / 2.0);</div><div class="line"><a name="l00275"></a><span class="lineno"> 275</span>  ret.y = 0;</div><div class="line"><a name="l00276"></a><span class="lineno"> 276</span>  }</div><div class="line"><a name="l00277"></a><span class="lineno"> 277</span>  <span class="keywordflow">return</span> ret;</div><div class="line"><a name="l00278"></a><span class="lineno"> 278</span> }</div><div class="line"><a name="l00279"></a><span class="lineno"> 279</span> </div><div class="line"><a name="l00280"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#aa3d42bf838d369bc4e1f15459277a4d3"> 280</a></span> QImage &<a class="code" href="class_face_detect_algorithm.html#aa3d42bf838d369bc4e1f15459277a4d3">FaceDetectAlgorithm::getQImageMarked</a>()</div><div class="line"><a name="l00281"></a><span class="lineno"> 281</span> {</div><div class="line"><a name="l00282"></a><span class="lineno"> 282</span>  <span class="keywordflow">return</span> <a class="code" href="class_face_detect_algorithm.html#a40a615a5ef1c1e0df9a1f19a179753a5">mQImageMarked</a>;</div><div class="line"><a name="l00283"></a><span class="lineno"> 283</span> }</div><div class="line"><a name="l00284"></a><span class="lineno"> 284</span> </div><div class="line"><a name="l00289"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#aafc62426e6556a7d9b5ad333a6893946"> 289</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#aafc62426e6556a7d9b5ad333a6893946">FaceDetectAlgorithm::resizeMarkedImage</a>()</div><div class="line"><a name="l00290"></a><span class="lineno"> 290</span> {</div><div class="line"><a name="l00291"></a><span class="lineno"> 291</span>  MyDebug;</div><div class="line"><a name="l00292"></a><span class="lineno"> 292</span>  Mat image_marked_tmp;</div><div class="line"><a name="l00293"></a><span class="lineno"> 293</span>  cv::resize(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>, image_marked_tmp, Size(this-><a class="code" href="class_face_detect_algorithm.html#a750758d7a4c23837f3d6400e6254d956">gui_show_width</a>, this-><a class="code" href="class_face_detect_algorithm.html#a8de13a75ed483c91e701dd64b88656d5">gui_show_height</a>));</div><div class="line"><a name="l00294"></a><span class="lineno"> 294</span>  <a class="code" href="class_common.html#afedb72b72fb5f44689d9c8f071b5cd6a">Common::Mat2QImage</a>( image_marked_tmp, <a class="code" href="class_face_detect_algorithm.html#a40a615a5ef1c1e0df9a1f19a179753a5">mQImageMarked</a>);</div><div class="line"><a name="l00295"></a><span class="lineno"> 295</span> }</div><div class="line"><a name="l00296"></a><span class="lineno"> 296</span> </div><div class="line"><a name="l00297"></a><span class="lineno"> 297</span> </div><div class="line"><a name="l00298"></a><span class="lineno"> 298</span> </div><div class="line"><a name="l00299"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a58001098fdbff06d6daf128e0633941c"> 299</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#a58001098fdbff06d6daf128e0633941c">FaceDetectAlgorithm::startDetect</a>(Mat &<a class="code" href="class_face_detect_algorithm.html#a684f7c8e0a48ce767f887b292911432c">src_image</a>, QImage &image_marked_, <a class="code" href="_common_8h.html#a2fe90c93732769fe3c27a120289aba6f">FACE_OPTION</a> <a class="code" href="class_face_detect_algorithm.html#a77f338b5761deb6eec17a5787e0e619c">option</a>)</div><div class="line"><a name="l00300"></a><span class="lineno"> 300</span> {</div><div class="line"><a name="l00301"></a><span class="lineno"> 301</span>  MyDebug;</div><div class="line"><a name="l00302"></a><span class="lineno"> 302</span>  <a class="code" href="class_face_detect_algorithm.html#a991fa171a609804fea4647593bc0b126">clear</a>();</div><div class="line"><a name="l00303"></a><span class="lineno"> 303</span>  src_image.copyTo(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>);</div><div class="line"><a name="l00304"></a><span class="lineno"> 304</span>  <span class="keywordflow">switch</span> (option) {</div><div class="line"><a name="l00305"></a><span class="lineno"> 305</span>  <span class="keywordflow">case</span> <a class="code" href="_common_8h.html#a2fe90c93732769fe3c27a120289aba6fa390a13f20d990fee5f89d3b64e959e5a">FACE_FISHER_SINGLE</a>: <span class="comment">//仅检测一张脸</span></div><div class="line"><a name="l00306"></a><span class="lineno"> 306</span>  <a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#ad22ca7aed5cefb7e43f9e961dc618242">start</a>(src_image, <a class="code" href="class_face_detect_algorithm.html#a2844c14c1d0382e99bf61406a7be5d1a">eye_left</a>, <a class="code" href="class_face_detect_algorithm.html#a2734f9d2a35b7069b0439a12cb65432f">eye_right</a>, <a class="code" href="class_face_detect_algorithm.html#a1fa6194eb73cf9bd9926a481447b09d5">face_location</a>, <a class="code" href="class_face_detect_algorithm.html#a9a66959d5f932ae9058506a96c14c084">reconstructedFace</a>);</div><div class="line"><a name="l00307"></a><span class="lineno"> 307</span>  <a class="code" href="class_face_detect_algorithm.html#a12d8994f5eea57fe54ce731e8a5b1374">showFaceMarker</a>();</div><div class="line"><a name="l00308"></a><span class="lineno"> 308</span>  <a class="code" href="class_face_detect_algorithm.html#a5fd2a744896e3b28a2ef7b1009e156e3">showEyesMarker</a>();</div><div class="line"><a name="l00309"></a><span class="lineno"> 309</span> </div><div class="line"><a name="l00310"></a><span class="lineno"> 310</span>  <span class="keywordflow">if</span> (this-><a class="code" href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">fisher_detector</a>.<a class="code" href="class_fisherfaces_recognition.html#a5b359dd6ea6f4671fe5af7f34cbcc012">fisher_mode</a> == <a class="code" href="_common_8h.html#a13bce11aca45a14b793b12be56a00f16a4c6039abaf1081121f56eefabbad5eb4">MODE_RECOGNITION</a>)</div><div class="line"><a name="l00311"></a><span class="lineno"> 311</span>  <a class="code" href="class_face_detect_algorithm.html#ae151eb8e68476b58ce58c9536dcc1c15">showConfidenceRatio</a>();</div><div class="line"><a name="l00312"></a><span class="lineno"> 312</span>  <span class="keywordflow">break</span>;</div><div class="line"><a name="l00313"></a><span class="lineno"> 313</span>  <span class="keywordflow">case</span> <a class="code" href="_common_8h.html#a2fe90c93732769fe3c27a120289aba6fa545d8d558382b4c457d185a71421072f">FACE_FISHER_MULTI</a>: <span class="comment">// 检测图像中所有的脸</span></div><div class="line"><a name="l00314"></a><span class="lineno"> 314</span> </div><div class="line"><a name="l00315"></a><span class="lineno"> 315</span>  <span class="keywordflow">default</span>:</div><div class="line"><a name="l00316"></a><span class="lineno"> 316</span>  <span class="keywordflow">break</span>;</div><div class="line"><a name="l00317"></a><span class="lineno"> 317</span>  }</div><div class="line"><a name="l00318"></a><span class="lineno"> 318</span>  <a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a> = <a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>(<a class="code" href="class_face_detect_algorithm.html#a0e55749daeb0c8f250ce3be15c4c5fb8">getShowRect</a>(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>));</div><div class="line"><a name="l00319"></a><span class="lineno"> 319</span>  <a class="code" href="class_face_detect_algorithm.html#a4c9102e71cc835b0ceb058fcff46c342">showHelp</a>();</div><div class="line"><a name="l00320"></a><span class="lineno"> 320</span>  <a class="code" href="class_face_detect_algorithm.html#a6ea81eaab10f64cfc354b0e1746746d4">showCurrentMode</a>();</div><div class="line"><a name="l00321"></a><span class="lineno"> 321</span>  <a class="code" href="class_face_detect_algorithm.html#a2a2ee1334b59a677cbb1ae1d97006ca5">showPreprocessFace</a>();</div><div class="line"><a name="l00322"></a><span class="lineno"> 322</span>  <a class="code" href="class_face_detect_algorithm.html#a00cd48891549b3fbc8587cd33fc5020b">showRecentFaces</a>();</div><div class="line"><a name="l00323"></a><span class="lineno"> 323</span>  <a class="code" href="class_face_detect_algorithm.html#aafc62426e6556a7d9b5ad333a6893946">resizeMarkedImage</a>();</div><div class="line"><a name="l00324"></a><span class="lineno"> 324</span>  <span class="comment">//showDebugData(src_image);</span></div><div class="line"><a name="l00325"></a><span class="lineno"> 325</span>  image_marked_ = <a class="code" href="class_face_detect_algorithm.html#a40a615a5ef1c1e0df9a1f19a179753a5">mQImageMarked</a>;</div><div class="line"><a name="l00326"></a><span class="lineno"> 326</span> }</div><div class="line"><a name="l00327"></a><span class="lineno"> 327</span> </div><div class="line"><a name="l00332"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a9e08ba9cbd831b78fdd5213abcba3d31"> 332</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#a9e08ba9cbd831b78fdd5213abcba3d31">FaceDetectAlgorithm::startLandMark</a>(<span class="keyword">const</span> <a class="code" href="struct_deep_cam_data.html">DeepCamData</a> &image_data, QImage &image_marked_, std::vector<Point2f> &<a class="code" href="class_face_detect_algorithm.html#a8a2dccb8f7f9540074872a7d441e1168">landmark_points</a>,std::vector<cv::Point3f> &landmark_3Dpoint)</div><div class="line"><a name="l00333"></a><span class="lineno"> 333</span> {</div><div class="line"><a name="l00334"></a><span class="lineno"> 334</span>  MyDebug;</div><div class="line"><a name="l00335"></a><span class="lineno"> 335</span>  <a class="code" href="class_face_detect_algorithm.html#a991fa171a609804fea4647593bc0b126">clear</a>();</div><div class="line"><a name="l00336"></a><span class="lineno"> 336</span> </div><div class="line"><a name="l00337"></a><span class="lineno"> 337</span>  <span class="comment">//image_data.mCvAlignRgb->copyTo(image_marked);</span></div><div class="line"><a name="l00338"></a><span class="lineno"> 338</span>  image_data.<a class="code" href="struct_deep_cam_data.html#ada26d0acd6ed3e2dd93dc9118779cf7e">mCvRgb</a>->copyTo(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>);</div><div class="line"><a name="l00339"></a><span class="lineno"> 339</span>  <span class="comment">//src_image.copyTo(image_marked);</span></div><div class="line"><a name="l00340"></a><span class="lineno"> 340</span>  <span class="comment">//mHeadTrack.startLandmark(*(image_data.mCvRgb), landmark_points);</span></div><div class="line"><a name="l00341"></a><span class="lineno"> 341</span>  <a class="code" href="class_face_detect_algorithm.html#af1790d7f75292be561f2433b20b2dd13">mHeadTrack</a>.<a class="code" href="class_head_track.html#abf7c1c7b3f0db202c336c455729a20c1">startLandmark</a>(image_data, landmark_points,landmark_3Dpoint);</div><div class="line"><a name="l00342"></a><span class="lineno"> 342</span>  <span class="comment">//mHeadTrack.startLandmark(*(image_data.mCvAlignRgb), landmark_points);</span></div><div class="line"><a name="l00343"></a><span class="lineno"> 343</span>  <a class="code" href="class_face_detect_algorithm.html#a1fa6194eb73cf9bd9926a481447b09d5">face_location</a> = <a class="code" href="class_face_detect_algorithm.html#af1790d7f75292be561f2433b20b2dd13">mHeadTrack</a>.<a class="code" href="class_head_track.html#aa5c20fb7cc917f55ef5e439f6e025f15">getFaceLocation</a>();<span class="comment">// it did nothing in realsense!!!</span></div><div class="line"><a name="l00344"></a><span class="lineno"> 344</span>  this-><a class="code" href="class_face_detect_algorithm.html#aa6c039b1d5e082c44e438280d2583246">showLandMarkPoint</a>();</div><div class="line"><a name="l00345"></a><span class="lineno"> 345</span>  <a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a> = <a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>(<a class="code" href="class_face_detect_algorithm.html#a0e55749daeb0c8f250ce3be15c4c5fb8">getShowRect</a>(<a class="code" href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">image_marked</a>));</div><div class="line"><a name="l00346"></a><span class="lineno"> 346</span>  <a class="code" href="class_face_detect_algorithm.html#aafc62426e6556a7d9b5ad333a6893946">resizeMarkedImage</a>();</div><div class="line"><a name="l00347"></a><span class="lineno"> 347</span>  image_marked_ = <a class="code" href="class_face_detect_algorithm.html#a40a615a5ef1c1e0df9a1f19a179753a5">mQImageMarked</a>;</div><div class="line"><a name="l00348"></a><span class="lineno"> 348</span> }</div><div class="line"><a name="l00349"></a><span class="lineno"> 349</span> </div><div class="line"><a name="l00350"></a><span class="lineno"><a class="line" href="class_face_detect_algorithm.html#a991fa171a609804fea4647593bc0b126"> 350</a></span> <span class="keywordtype">void</span> <a class="code" href="class_face_detect_algorithm.html#a991fa171a609804fea4647593bc0b126">FaceDetectAlgorithm::clear</a>()</div><div class="line"><a name="l00351"></a><span class="lineno"> 351</span> {</div><div class="line"><a name="l00352"></a><span class="lineno"> 352</span>  MyDebug;</div><div class="line"><a name="l00353"></a><span class="lineno"> 353</span>  this-><a class="code" href="class_face_detect_algorithm.html#adaf2adfd8aebf272e3ec982999d412a1">reconstructed_face_multi</a>.clear();</div><div class="line"><a name="l00354"></a><span class="lineno"> 354</span>  this-><a class="code" href="class_face_detect_algorithm.html#a07c70f6b5132f6c0609c4c892f15dd2e">eye_left_multi</a>.clear();</div><div class="line"><a name="l00355"></a><span class="lineno"> 355</span>  this-><a class="code" href="class_face_detect_algorithm.html#aea993eeb58ba7b2d4624cbfcc212742f">eye_right_multi</a>.clear();</div><div class="line"><a name="l00356"></a><span class="lineno"> 356</span>  this-><a class="code" href="class_face_detect_algorithm.html#a8c868b799cb506b2be546547f20771e9">face_location_multi</a>.clear();</div><div class="line"><a name="l00357"></a><span class="lineno"> 357</span>  this-><a class="code" href="class_face_detect_algorithm.html#a8a2dccb8f7f9540074872a7d441e1168">landmark_points</a>.clear();</div><div class="line"><a name="l00358"></a><span class="lineno"> 358</span>  this-><a class="code" href="class_face_detect_algorithm.html#ad6908d010307a35aeda5526b3cc193c3">landmark_points_multi</a>.clear();</div><div class="line"><a name="l00359"></a><span class="lineno"> 359</span> }</div><div class="ttc" id="class_face_detect_algorithm_html_a2734f9d2a35b7069b0439a12cb65432f"><div class="ttname"><a href="class_face_detect_algorithm.html#a2734f9d2a35b7069b0439a12cb65432f">FaceDetectAlgorithm::eye_right</a></div><div class="ttdeci">cv::Point eye_right</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00061">FaceDetectAlgorithm.h:61</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_ae151eb8e68476b58ce58c9536dcc1c15"><div class="ttname"><a href="class_face_detect_algorithm.html#ae151eb8e68476b58ce58c9536dcc1c15">FaceDetectAlgorithm::showConfidenceRatio</a></div><div class="ttdeci">void showConfidenceRatio()</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00082">FaceDetectAlgorithm.cpp:82</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a1af5c8e516f5f2b821ed4ef26da53adb"><div class="ttname"><a href="class_face_detect_algorithm.html#a1af5c8e516f5f2b821ed4ef26da53adb">FaceDetectAlgorithm::setFaceRectColor</a></div><div class="ttdeci">void setFaceRectColor(const cv::Scalar &color)</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00237">FaceDetectAlgorithm.cpp:237</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a2402774af43118bc1c81832c492d0edf"><div class="ttname"><a href="class_face_detect_algorithm.html#a2402774af43118bc1c81832c492d0edf">FaceDetectAlgorithm::setEyeCircleColor</a></div><div class="ttdeci">void setEyeCircleColor(const cv::Scalar &color)</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00231">FaceDetectAlgorithm.cpp:231</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a77f338b5761deb6eec17a5787e0e619c"><div class="ttname"><a href="class_face_detect_algorithm.html#a77f338b5761deb6eec17a5787e0e619c">FaceDetectAlgorithm::option</a></div><div class="ttdeci">FACE_OPTION option</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00082">FaceDetectAlgorithm.h:82</a></div></div>
<div class="ttc" id="_common_8h_html_a2fe90c93732769fe3c27a120289aba6fa390a13f20d990fee5f89d3b64e959e5a"><div class="ttname"><a href="_common_8h.html#a2fe90c93732769fe3c27a120289aba6fa390a13f20d990fee5f89d3b64e959e5a">FACE_FISHER_SINGLE</a></div><div class="ttdef"><b>Definition:</b> <a href="_common_8h_source.html#l00087">Common.h:87</a></div></div>
<div class="ttc" id="class_fisherfaces_recognition_html_ab7620661e0e1175c5b418716f187a746"><div class="ttname"><a href="class_fisherfaces_recognition.html#ab7620661e0e1175c5b418716f187a746">FisherfacesRecognition::fisher_debug</a></div><div class="ttdeci">bool fisher_debug</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8h_source.html#l00132">FisherfacesRecognition.h:132</a></div></div>
<div class="ttc" id="process__1_8m_html_a8c4e28b0ee15a1005df90b45f3b82ea8"><div class="ttname"><a href="process__1_8m.html#a8c4e28b0ee15a1005df90b45f3b82ea8">i</a></div><div class="ttdeci">Speed_z target for i</div><div class="ttdef"><b>Definition:</b> <a href="process__1_8m_source.html#l00081">process_1.m:81</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a750758d7a4c23837f3d6400e6254d956"><div class="ttname"><a href="class_face_detect_algorithm.html#a750758d7a4c23837f3d6400e6254d956">FaceDetectAlgorithm::gui_show_width</a></div><div class="ttdeci">int gui_show_width</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00078">FaceDetectAlgorithm.h:78</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_aead21cb252c0fd97454a9c2e99b7a4b8"><div class="ttname"><a href="class_face_detect_algorithm.html#aead21cb252c0fd97454a9c2e99b7a4b8">FaceDetectAlgorithm::eye_circle_color</a></div><div class="ttdeci">cv::Scalar eye_circle_color</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00073">FaceDetectAlgorithm.h:73</a></div></div>
<div class="ttc" id="class_common_html_afedb72b72fb5f44689d9c8f071b5cd6a"><div class="ttname"><a href="class_common.html#afedb72b72fb5f44689d9c8f071b5cd6a">Common::Mat2QImage</a></div><div class="ttdeci">static void Mat2QImage(const cv::Mat &cvImg, QImage &qImage_out)</div><div class="ttdef"><b>Definition:</b> <a href="_common_8cpp_source.html#l00053">Common.cpp:53</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a8a2dccb8f7f9540074872a7d441e1168"><div class="ttname"><a href="class_face_detect_algorithm.html#a8a2dccb8f7f9540074872a7d441e1168">FaceDetectAlgorithm::landmark_points</a></div><div class="ttdeci">std::vector< cv::Point2f > landmark_points</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00063">FaceDetectAlgorithm.h:63</a></div></div>
<div class="ttc" id="class_preprocess_face_html_a94616b0b0118bea878f2d1ef6651fd50"><div class="ttname"><a href="class_preprocess_face.html#a94616b0b0118bea878f2d1ef6651fd50">PreprocessFace::at</a></div><div class="ttdeci">cv::Mat & at(size_t n)</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8cpp_source.html#l00972">FisherfacesRecognition.cpp:972</a></div></div>
<div class="ttc" id="class_preprocess_face_html_a02f44831902ebc0489ae8c890639b2a2"><div class="ttname"><a href="class_preprocess_face.html#a02f44831902ebc0489ae8c890639b2a2">PreprocessFace::searchedLeftEye</a></div><div class="ttdeci">std::vector< cv::Rect > searchedLeftEye</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8h_source.html#l00058">FisherfacesRecognition.h:58</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a00cd48891549b3fbc8587cd33fc5020b"><div class="ttname"><a href="class_face_detect_algorithm.html#a00cd48891549b3fbc8587cd33fc5020b">FaceDetectAlgorithm::showRecentFaces</a></div><div class="ttdeci">void showRecentFaces()</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00130">FaceDetectAlgorithm.cpp:130</a></div></div>
<div class="ttc" id="class_preprocess_face_html_a2466930f9d2bb40eb974e2eff163fcfd"><div class="ttname"><a href="class_preprocess_face.html#a2466930f9d2bb40eb974e2eff163fcfd">PreprocessFace::empty</a></div><div class="ttdeci">bool empty() const</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8cpp_source.html#l01018">FisherfacesRecognition.cpp:1018</a></div></div>
<div class="ttc" id="class_preprocess_face_html_af0b1d20e88d77e0ef8478fd6a9dce0d7"><div class="ttname"><a href="class_preprocess_face.html#af0b1d20e88d77e0ef8478fd6a9dce0d7">PreprocessFace::size</a></div><div class="ttdeci">size_t size() const</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8cpp_source.html#l01001">FisherfacesRecognition.cpp:1001</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_aa6c039b1d5e082c44e438280d2583246"><div class="ttname"><a href="class_face_detect_algorithm.html#aa6c039b1d5e082c44e438280d2583246">FaceDetectAlgorithm::showLandMarkPoint</a></div><div class="ttdeci">void showLandMarkPoint()</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00184">FaceDetectAlgorithm.cpp:184</a></div></div>
<div class="ttc" id="class_fisherfaces_recognition_html_a2c8453e74e29ab69bd16fb8a36a5a41a"><div class="ttname"><a href="class_fisherfaces_recognition.html#a2c8453e74e29ab69bd16fb8a36a5a41a">FisherfacesRecognition::getCollectionNum</a></div><div class="ttdeci">int getCollectionNum() const</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8cpp_source.html#l00342">FisherfacesRecognition.cpp:342</a></div></div>
<div class="ttc" id="struct_deep_cam_data_html"><div class="ttname"><a href="struct_deep_cam_data.html">DeepCamData</a></div><div class="ttdef"><b>Definition:</b> <a href="_deep_camera_interface_8h_source.html#l00040">DeepCameraInterface.h:40</a></div></div>
<div class="ttc" id="_common_8h_html_a13bce11aca45a14b793b12be56a00f16af2c99680641133a2b366c25bb6719df3"><div class="ttname"><a href="_common_8h.html#a13bce11aca45a14b793b12be56a00f16af2c99680641133a2b366c25bb6719df3">MODE_DETECTION</a></div><div class="ttdef"><b>Definition:</b> <a href="_common_8h_source.html#l00077">Common.h:77</a></div></div>
<div class="ttc" id="class_fisherfaces_recognition_html_a32e3a8c4908862fb3722732d82d73682"><div class="ttname"><a href="class_fisherfaces_recognition.html#a32e3a8c4908862fb3722732d82d73682">FisherfacesRecognition::getNumPersions</a></div><div class="ttdeci">int getNumPersions() const</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8cpp_source.html#l00337">FisherfacesRecognition.cpp:337</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_ac0be172b2983ad69dbb4f09df4ee882d"><div class="ttname"><a href="class_face_detect_algorithm.html#ac0be172b2983ad69dbb4f09df4ee882d">FaceDetectAlgorithm::FaceDetectAlgorithm</a></div><div class="ttdeci">FaceDetectAlgorithm(QObject *parent=nullptr)</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00005">FaceDetectAlgorithm.cpp:5</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_aa3d42bf838d369bc4e1f15459277a4d3"><div class="ttname"><a href="class_face_detect_algorithm.html#aa3d42bf838d369bc4e1f15459277a4d3">FaceDetectAlgorithm::getQImageMarked</a></div><div class="ttdeci">QImage & getQImageMarked()</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00280">FaceDetectAlgorithm.cpp:280</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_af1790d7f75292be561f2433b20b2dd13"><div class="ttname"><a href="class_face_detect_algorithm.html#af1790d7f75292be561f2433b20b2dd13">FaceDetectAlgorithm::mHeadTrack</a></div><div class="ttdeci">HeadTrack mHeadTrack</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00055">FaceDetectAlgorithm.h:55</a></div></div>
<div class="ttc" id="_common_8h_html_a2fe90c93732769fe3c27a120289aba6fa545d8d558382b4c457d185a71421072f"><div class="ttname"><a href="_common_8h.html#a2fe90c93732769fe3c27a120289aba6fa545d8d558382b4c457d185a71421072f">FACE_FISHER_MULTI</a></div><div class="ttdef"><b>Definition:</b> <a href="_common_8h_source.html#l00088">Common.h:88</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_aaef97b55f3011a315bb4f544e3bf9ac6"><div class="ttname"><a href="class_face_detect_algorithm.html#aaef97b55f3011a315bb4f544e3bf9ac6">FaceDetectAlgorithm::drawCircle</a></div><div class="ttdeci">void drawCircle(cv::Point &point_center, int radius, const cv::Scalar &color, int thickness=1, int linetype=8)</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00021">FaceDetectAlgorithm.cpp:21</a></div></div>
<div class="ttc" id="namespace_configuration_html_aabd7b608d1256e4e08b15ec0e35c4483"><div class="ttname"><a href="namespace_configuration.html#aabd7b608d1256e4e08b15ec0e35c4483">Configuration::UNKNOWN_PERSON_THRESHOLD</a></div><div class="ttdeci">const float UNKNOWN_PERSON_THRESHOLD</div><div class="ttdef"><b>Definition:</b> <a href="_configuration_8h_source.html#l00044">Configuration.h:44</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_aea993eeb58ba7b2d4624cbfcc212742f"><div class="ttname"><a href="class_face_detect_algorithm.html#aea993eeb58ba7b2d4624cbfcc212742f">FaceDetectAlgorithm::eye_right_multi</a></div><div class="ttdeci">std::vector< cv::Point > eye_right_multi</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00069">FaceDetectAlgorithm.h:69</a></div></div>
<div class="ttc" id="namespacestd_html"><div class="ttname"><a href="namespacestd.html">std</a></div></div>
<div class="ttc" id="_common_8h_html_a13bce11aca45a14b793b12be56a00f16a4c6039abaf1081121f56eefabbad5eb4"><div class="ttname"><a href="_common_8h.html#a13bce11aca45a14b793b12be56a00f16a4c6039abaf1081121f56eefabbad5eb4">MODE_RECOGNITION</a></div><div class="ttdef"><b>Definition:</b> <a href="_common_8h_source.html#l00080">Common.h:80</a></div></div>
<div class="ttc" id="namespacecv_html"><div class="ttname"><a href="namespacecv.html">cv</a></div></div>
<div class="ttc" id="class_preprocess_face_html_a9f7771b65c57d2294e0ee258eaaa15e3"><div class="ttname"><a href="class_preprocess_face.html#a9f7771b65c57d2294e0ee258eaaa15e3">PreprocessFace::searchedRightEye</a></div><div class="ttdeci">std::vector< cv::Rect > searchedRightEye</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8h_source.html#l00059">FisherfacesRecognition.h:59</a></div></div>
<div class="ttc" id="class_fisherfaces_recognition_html_aa98ba6019ca7c1a37d9fe2ad0a10978d"><div class="ttname"><a href="class_fisherfaces_recognition.html#aa98ba6019ca7c1a37d9fe2ad0a10978d">FisherfacesRecognition::getIdentity</a></div><div class="ttdeci">int getIdentity() const</div><div class="ttdoc">FisherfacesRecognition::getIdentity. </div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8cpp_source.html#l00357">FisherfacesRecognition.cpp:357</a></div></div>
<div class="ttc" id="_face_detect_algorithm_8h_html"><div class="ttname"><a href="_face_detect_algorithm_8h.html">FaceDetectAlgorithm.h</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a9e08ba9cbd831b78fdd5213abcba3d31"><div class="ttname"><a href="class_face_detect_algorithm.html#a9e08ba9cbd831b78fdd5213abcba3d31">FaceDetectAlgorithm::startLandMark</a></div><div class="ttdeci">void startLandMark(const DeepCamData &image_data, QImage &image_marked, std::vector< cv::Point2f > &landmark_points, std::vector< cv::Point3f > &landmark_3Dpoint)</div><div class="ttdoc">finding landmark points and disp these points. </div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00332">FaceDetectAlgorithm.cpp:332</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a2a2ee1334b59a677cbb1ae1d97006ca5"><div class="ttname"><a href="class_face_detect_algorithm.html#a2a2ee1334b59a677cbb1ae1d97006ca5">FaceDetectAlgorithm::showPreprocessFace</a></div><div class="ttdeci">void showPreprocessFace()</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00103">FaceDetectAlgorithm.cpp:103</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a4c9102e71cc835b0ceb058fcff46c342"><div class="ttname"><a href="class_face_detect_algorithm.html#a4c9102e71cc835b0ceb058fcff46c342">FaceDetectAlgorithm::showHelp</a></div><div class="ttdeci">void showHelp()</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00193">FaceDetectAlgorithm.cpp:193</a></div></div>
<div class="ttc" id="namespace_configuration_html_adb7fd1f86bf07d56bcca190c05847582"><div class="ttname"><a href="namespace_configuration.html#adb7fd1f86bf07d56bcca190c05847582">Configuration::DESIRED_FACE_WIDTH</a></div><div class="ttdeci">const int DESIRED_FACE_WIDTH</div><div class="ttdef"><b>Definition:</b> <a href="_configuration_8h_source.html#l00059">Configuration.h:59</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a2844c14c1d0382e99bf61406a7be5d1a"><div class="ttname"><a href="class_face_detect_algorithm.html#a2844c14c1d0382e99bf61406a7be5d1a">FaceDetectAlgorithm::eye_left</a></div><div class="ttdeci">cv::Point eye_left</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00060">FaceDetectAlgorithm.h:60</a></div></div>
<div class="ttc" id="class_fisherfaces_recognition_html_aedfd142d604b9b6f2bc2e5acc2f2b1a9"><div class="ttname"><a href="class_fisherfaces_recognition.html#aedfd142d604b9b6f2bc2e5acc2f2b1a9">FisherfacesRecognition::showTrainingDebugData</a></div><div class="ttdeci">void showTrainingDebugData()</div><div class="ttdoc">FisherfacesRecognition::showTrainingDebugData Show the internal face recognition data...</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8cpp_source.html#l00046">FisherfacesRecognition.cpp:46</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a6ea81eaab10f64cfc354b0e1746746d4"><div class="ttname"><a href="class_face_detect_algorithm.html#a6ea81eaab10f64cfc354b0e1746746d4">FaceDetectAlgorithm::showCurrentMode</a></div><div class="ttdeci">void showCurrentMode()</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00219">FaceDetectAlgorithm.cpp:219</a></div></div>
<div class="ttc" id="class_fisherfaces_recognition_html_a6069e77ca4b911295f96b059c86916f0"><div class="ttname"><a href="class_fisherfaces_recognition.html#a6069e77ca4b911295f96b059c86916f0">FisherfacesRecognition::getPersionId</a></div><div class="ttdeci">int getPersionId() const</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8cpp_source.html#l00332">FisherfacesRecognition.cpp:332</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a07c70f6b5132f6c0609c4c892f15dd2e"><div class="ttname"><a href="class_face_detect_algorithm.html#a07c70f6b5132f6c0609c4c892f15dd2e">FaceDetectAlgorithm::eye_left_multi</a></div><div class="ttdeci">std::vector< cv::Point > eye_left_multi</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00068">FaceDetectAlgorithm.h:68</a></div></div>
<div class="ttc" id="class_common_html_ab7f5af0f1add62eb22f6f9e04b9d9efa"><div class="ttname"><a href="class_common.html#ab7f5af0f1add62eb22f6f9e04b9d9efa">Common::MODE_NAME</a></div><div class="ttdeci">static std::vector< std::string > MODE_NAME</div><div class="ttdef"><b>Definition:</b> <a href="_common_8h_source.html#l00055">Common.h:55</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a5fd2a744896e3b28a2ef7b1009e156e3"><div class="ttname"><a href="class_face_detect_algorithm.html#a5fd2a744896e3b28a2ef7b1009e156e3">FaceDetectAlgorithm::showEyesMarker</a></div><div class="ttdeci">void showEyesMarker()</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00068">FaceDetectAlgorithm.cpp:68</a></div></div>
<div class="ttc" id="_common_8h_html_a13bce11aca45a14b793b12be56a00f16a406ca8d89d280d3561c76fead32d5aa5"><div class="ttname"><a href="_common_8h.html#a13bce11aca45a14b793b12be56a00f16a406ca8d89d280d3561c76fead32d5aa5">MODE_END</a></div><div class="ttdef"><b>Definition:</b> <a href="_common_8h_source.html#l00082">Common.h:82</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a2dd7def401b83e4d29a3dee19a227c30"><div class="ttname"><a href="class_face_detect_algorithm.html#a2dd7def401b83e4d29a3dee19a227c30">FaceDetectAlgorithm::drawString</a></div><div class="ttdeci">cv::Rect drawString(cv::Mat &img, std::string text, cv::Point coord, cv::Scalar color, float fontScale=0.6f, int thickness=1, int fontFace=cv::FONT_HERSHEY_COMPLEX)</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00027">FaceDetectAlgorithm.cpp:27</a></div></div>
<div class="ttc" id="_common_8h_html_a13bce11aca45a14b793b12be56a00f16a154d714d5660ce2f2caf4376858f35c0"><div class="ttname"><a href="_common_8h.html#a13bce11aca45a14b793b12be56a00f16a154d714d5660ce2f2caf4376858f35c0">MODE_COLLECT_FACES</a></div><div class="ttdef"><b>Definition:</b> <a href="_common_8h_source.html#l00078">Common.h:78</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a019f7d08e7bc24239808946c33d08ebe"><div class="ttname"><a href="class_face_detect_algorithm.html#a019f7d08e7bc24239808946c33d08ebe">FaceDetectAlgorithm::showDebugData</a></div><div class="ttdeci">void showDebugData(cv::Mat &src_image)</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00157">FaceDetectAlgorithm.cpp:157</a></div></div>
<div class="ttc" id="class_fisher_model_entity_html_af6d16b989d4151ff521f80aa08b6d488"><div class="ttname"><a href="class_fisher_model_entity.html#af6d16b989d4151ff521f80aa08b6d488">FisherModelEntity::data</a></div><div class="ttdeci">cv::Ptr< cv::face::FisherFaceRecognizer > data</div><div class="ttdef"><b>Definition:</b> <a href="_fisher_model_entity_8h_source.html#l00042">FisherModelEntity.h:42</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a66be266c9ff83e6eb8026265610a3437"><div class="ttname"><a href="class_face_detect_algorithm.html#a66be266c9ff83e6eb8026265610a3437">FaceDetectAlgorithm::rcHelp</a></div><div class="ttdeci">cv::Rect rcHelp</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00075">FaceDetectAlgorithm.h:75</a></div></div>
<div class="ttc" id="class_head_track_html_aa5c20fb7cc917f55ef5e439f6e025f15"><div class="ttname"><a href="class_head_track.html#aa5c20fb7cc917f55ef5e439f6e025f15">HeadTrack::getFaceLocation</a></div><div class="ttdeci">cv::Rect getFaceLocation() const</div><div class="ttdef"><b>Definition:</b> <a href="_head_track_8cpp_source.html#l00359">HeadTrack.cpp:359</a></div></div>
<div class="ttc" id="class_fisherfaces_recognition_html_ad22ca7aed5cefb7e43f9e961dc618242"><div class="ttname"><a href="class_fisherfaces_recognition.html#ad22ca7aed5cefb7e43f9e961dc618242">FisherfacesRecognition::start</a></div><div class="ttdeci">void start(cv::Mat &src_image, cv::Point &eye_left, cv::Point &eye_right, cv::Rect &face_location, cv::Mat &reconstructedFace)</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8cpp_source.html#l00273">FisherfacesRecognition.cpp:273</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a8e979a1b2b2d8de43757c2c61e07f962"><div class="ttname"><a href="class_face_detect_algorithm.html#a8e979a1b2b2d8de43757c2c61e07f962">FaceDetectAlgorithm::fisher_detector</a></div><div class="ttdeci">FisherfacesRecognition fisher_detector</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00054">FaceDetectAlgorithm.h:54</a></div></div>
<div class="ttc" id="class_fisherfaces_recognition_html_a5b359dd6ea6f4671fe5af7f34cbcc012"><div class="ttname"><a href="class_fisherfaces_recognition.html#a5b359dd6ea6f4671fe5af7f34cbcc012">FisherfacesRecognition::fisher_mode</a></div><div class="ttdeci">FISHERMODES fisher_mode</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8h_source.html#l00102">FisherfacesRecognition.h:102</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_aafc62426e6556a7d9b5ad333a6893946"><div class="ttname"><a href="class_face_detect_algorithm.html#aafc62426e6556a7d9b5ad333a6893946">FaceDetectAlgorithm::resizeMarkedImage</a></div><div class="ttdeci">void resizeMarkedImage()</div><div class="ttdoc">FaceDetectAlgorithm::getResizeMarkedImage. </div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00289">FaceDetectAlgorithm.cpp:289</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a9bcd32ec18b639f2598935c70c4d7760"><div class="ttname"><a href="class_face_detect_algorithm.html#a9bcd32ec18b639f2598935c70c4d7760">FaceDetectAlgorithm::face_rect_color</a></div><div class="ttdeci">cv::Scalar face_rect_color</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00074">FaceDetectAlgorithm.h:74</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a933a23a9fe1b84b0a0968d9abb526c0d"><div class="ttname"><a href="class_face_detect_algorithm.html#a933a23a9fe1b84b0a0968d9abb526c0d">FaceDetectAlgorithm::drawRect</a></div><div class="ttdeci">void drawRect(cv::Rect &rect, const cv::Scalar &color, int thickness=1, int linetype=8)</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00015">FaceDetectAlgorithm.cpp:15</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_adaf2adfd8aebf272e3ec982999d412a1"><div class="ttname"><a href="class_face_detect_algorithm.html#adaf2adfd8aebf272e3ec982999d412a1">FaceDetectAlgorithm::reconstructed_face_multi</a></div><div class="ttdeci">std::vector< cv::Mat > reconstructed_face_multi</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00067">FaceDetectAlgorithm.h:67</a></div></div>
<div class="ttc" id="struct_deep_cam_data_html_ada26d0acd6ed3e2dd93dc9118779cf7e"><div class="ttname"><a href="struct_deep_cam_data.html#ada26d0acd6ed3e2dd93dc9118779cf7e">DeepCamData::mCvRgb</a></div><div class="ttdeci">cv::Mat * mCvRgb</div><div class="ttdef"><b>Definition:</b> <a href="_deep_camera_interface_8h_source.html#l00046">DeepCameraInterface.h:46</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a991fa171a609804fea4647593bc0b126"><div class="ttname"><a href="class_face_detect_algorithm.html#a991fa171a609804fea4647593bc0b126">FaceDetectAlgorithm::clear</a></div><div class="ttdeci">void clear()</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00350">FaceDetectAlgorithm.cpp:350</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a8c868b799cb506b2be546547f20771e9"><div class="ttname"><a href="class_face_detect_algorithm.html#a8c868b799cb506b2be546547f20771e9">FaceDetectAlgorithm::face_location_multi</a></div><div class="ttdeci">std::vector< cv::Rect > face_location_multi</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00070">FaceDetectAlgorithm.h:70</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a1fa6194eb73cf9bd9926a481447b09d5"><div class="ttname"><a href="class_face_detect_algorithm.html#a1fa6194eb73cf9bd9926a481447b09d5">FaceDetectAlgorithm::face_location</a></div><div class="ttdeci">cv::Rect face_location</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00062">FaceDetectAlgorithm.h:62</a></div></div>
<div class="ttc" id="_common_8h_html_a13bce11aca45a14b793b12be56a00f16a9b5633a34baeeefaa0ce3f17936be149"><div class="ttname"><a href="_common_8h.html#a13bce11aca45a14b793b12be56a00f16a9b5633a34baeeefaa0ce3f17936be149">MODE_TRAINING</a></div><div class="ttdef"><b>Definition:</b> <a href="_common_8h_source.html#l00079">Common.h:79</a></div></div>
<div class="ttc" id="_common_8h_html_a2fe90c93732769fe3c27a120289aba6f"><div class="ttname"><a href="_common_8h.html#a2fe90c93732769fe3c27a120289aba6f">FACE_OPTION</a></div><div class="ttdeci">FACE_OPTION</div><div class="ttdef"><b>Definition:</b> <a href="_common_8h_source.html#l00085">Common.h:85</a></div></div>
<div class="ttc" id="class_fisherfaces_recognition_html_a0bee9594a637922f641d61ad7e448549"><div class="ttname"><a href="class_fisherfaces_recognition.html#a0bee9594a637922f641d61ad7e448549">FisherfacesRecognition::model</a></div><div class="ttdeci">FisherModelEntity model</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8h_source.html#l00131">FisherfacesRecognition.h:131</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a58001098fdbff06d6daf128e0633941c"><div class="ttname"><a href="class_face_detect_algorithm.html#a58001098fdbff06d6daf128e0633941c">FaceDetectAlgorithm::startDetect</a></div><div class="ttdeci">void startDetect(cv::Mat &src_image, QImage &image_marked_, FACE_OPTION option=FACE_FISHER_SINGLE)</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00299">FaceDetectAlgorithm.cpp:299</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a40a615a5ef1c1e0df9a1f19a179753a5"><div class="ttname"><a href="class_face_detect_algorithm.html#a40a615a5ef1c1e0df9a1f19a179753a5">FaceDetectAlgorithm::mQImageMarked</a></div><div class="ttdeci">QImage mQImageMarked</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00059">FaceDetectAlgorithm.h:59</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a0e55749daeb0c8f250ce3be15c4c5fb8"><div class="ttname"><a href="class_face_detect_algorithm.html#a0e55749daeb0c8f250ce3be15c4c5fb8">FaceDetectAlgorithm::getShowRect</a></div><div class="ttdeci">cv::Rect getShowRect(const cv::Mat &src_image)</div><div class="ttdoc">FaceDetectAlgorithm::getShowRect. </div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00255">FaceDetectAlgorithm.cpp:255</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_ad6908d010307a35aeda5526b3cc193c3"><div class="ttname"><a href="class_face_detect_algorithm.html#ad6908d010307a35aeda5526b3cc193c3">FaceDetectAlgorithm::landmark_points_multi</a></div><div class="ttdeci">std::vector< std::vector< cv::Point2f > > landmark_points_multi</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00071">FaceDetectAlgorithm.h:71</a></div></div>
<div class="ttc" id="class_head_track_html_abf7c1c7b3f0db202c336c455729a20c1"><div class="ttname"><a href="class_head_track.html#abf7c1c7b3f0db202c336c455729a20c1">HeadTrack::startLandmark</a></div><div class="ttdeci">void startLandmark(const DeepCamData &image_data, std::vector< cv::Point2f > &landmark_point, std::vector< cv::Point3f > &landmark_3Dpoint)</div><div class="ttdoc">get the landmark point fram deepCamrea image </div><div class="ttdef"><b>Definition:</b> <a href="_head_track_8cpp_source.html#l00054">HeadTrack.cpp:54</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a684f7c8e0a48ce767f887b292911432c"><div class="ttname"><a href="class_face_detect_algorithm.html#a684f7c8e0a48ce767f887b292911432c">FaceDetectAlgorithm::src_image</a></div><div class="ttdeci">cv::Mat * src_image</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00081">FaceDetectAlgorithm.h:81</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a12d8994f5eea57fe54ce731e8a5b1374"><div class="ttname"><a href="class_face_detect_algorithm.html#a12d8994f5eea57fe54ce731e8a5b1374">FaceDetectAlgorithm::showFaceMarker</a></div><div class="ttdeci">void showFaceMarker()</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00059">FaceDetectAlgorithm.cpp:59</a></div></div>
<div class="ttc" id="class_common_html_ab81ddd95b5858e34b620510cc45e9baa"><div class="ttname"><a href="class_common.html#ab81ddd95b5858e34b620510cc45e9baa">Common::toString</a></div><div class="ttdeci">static std::string toString(T t)</div><div class="ttdef"><b>Definition:</b> <a href="_common_8h_source.html#l00059">Common.h:59</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a9a66959d5f932ae9058506a96c14c084"><div class="ttname"><a href="class_face_detect_algorithm.html#a9a66959d5f932ae9058506a96c14c084">FaceDetectAlgorithm::reconstructedFace</a></div><div class="ttdeci">cv::Mat reconstructedFace</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00057">FaceDetectAlgorithm.h:57</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_af39515766bb1402bbfa0658001aa1cae"><div class="ttname"><a href="class_face_detect_algorithm.html#af39515766bb1402bbfa0658001aa1cae">FaceDetectAlgorithm::image_marked</a></div><div class="ttdeci">cv::Mat image_marked</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00058">FaceDetectAlgorithm.h:58</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_aa88289befbb9bece31e4c1bd8e1b82c0"><div class="ttname"><a href="class_face_detect_algorithm.html#aa88289befbb9bece31e4c1bd8e1b82c0">FaceDetectAlgorithm::setGUIShowRect</a></div><div class="ttdeci">void setGUIShowRect(const int &width, const int &height)</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8cpp_source.html#l00243">FaceDetectAlgorithm.cpp:243</a></div></div>
<div class="ttc" id="namespace_configuration_html_a67564f5567e1284f680fc181f6335350"><div class="ttname"><a href="namespace_configuration.html#a67564f5567e1284f680fc181f6335350">Configuration::BORDER</a></div><div class="ttdeci">const int BORDER</div><div class="ttdef"><b>Definition:</b> <a href="_configuration_8h_source.html#l00046">Configuration.h:46</a></div></div>
<div class="ttc" id="class_fisherfaces_recognition_html_aee98ff43d21ca7793f9f2e41f95ba61d"><div class="ttname"><a href="class_fisherfaces_recognition.html#aee98ff43d21ca7793f9f2e41f95ba61d">FisherfacesRecognition::preprocess</a></div><div class="ttdeci">PreprocessFace preprocess</div><div class="ttdef"><b>Definition:</b> <a href="_fisherfaces_recognition_8h_source.html#l00101">FisherfacesRecognition.h:101</a></div></div>
<div class="ttc" id="class_face_detect_algorithm_html_a8de13a75ed483c91e701dd64b88656d5"><div class="ttname"><a href="class_face_detect_algorithm.html#a8de13a75ed483c91e701dd64b88656d5">FaceDetectAlgorithm::gui_show_height</a></div><div class="ttdeci">int gui_show_height</div><div class="ttdef"><b>Definition:</b> <a href="_face_detect_algorithm_8h_source.html#l00079">FaceDetectAlgorithm.h:79</a></div></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by  <a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.13
</small></address>
</body>
</html>