Commit ae849ef422db603587242a850bbfe74f827736dc
1 parent
fe84de0b
Removed more compiler warnings
Showing
3 changed files
with
11 additions
and
3 deletions
3rdparty/stasm/stasm/stasm/src/facedet.cpp
| ... | ... | @@ -143,6 +143,8 @@ static void DiscardMissizedFaces( |
| 143 | 143 | } |
| 144 | 144 | } |
| 145 | 145 | |
| 146 | +#if TRACE_IMAGES // will be 0 unless debugging (defined in stasm.h) | |
| 147 | + | |
| 146 | 148 | static void TraceFaces( // write image showing detected face rects |
| 147 | 149 | const vec_DetPar& detpars, // in |
| 148 | 150 | const Image& img, // in |
| ... | ... | @@ -152,8 +154,6 @@ static void TraceFaces( // write image showing detected face rects |
| 152 | 154 | (void) img; |
| 153 | 155 | (void) path; |
| 154 | 156 | |
| 155 | -#if TRACE_IMAGES // will be 0 unless debugging (defined in stasm.h) | |
| 156 | - | |
| 157 | 157 | CImage cimg; cvtColor(img, cimg, CV_GRAY2BGR); // color image |
| 158 | 158 | for (int iface = 0; iface < NSIZE(detpars); iface++) |
| 159 | 159 | { |
| ... | ... | @@ -173,9 +173,10 @@ static void TraceFaces( // write image showing detected face rects |
| 173 | 173 | lprintf("%s\n", path); |
| 174 | 174 | if (!cv::imwrite(path, cimg)) |
| 175 | 175 | Err("Cannot write %s", path); |
| 176 | -#endif | |
| 177 | 176 | } |
| 178 | 177 | |
| 178 | +#endif | |
| 179 | + | |
| 179 | 180 | void FaceDet::DetectFaces_( // call once per image to find all the faces |
| 180 | 181 | const Image& img, // in: the image (grayscale) |
| 181 | 182 | const char* imgpath, // in: used only for debugging |
| ... | ... | @@ -184,7 +185,10 @@ void FaceDet::DetectFaces_( // call once per image to find all the faces |
| 184 | 185 | void* user, // in: unused (match virt func signature) |
| 185 | 186 | cv::CascadeClassifier cascade) |
| 186 | 187 | { |
| 188 | + (void) imgpath; | |
| 189 | + (void) user; | |
| 187 | 190 | DetectFaces(detpars_, img, minwidth, cascade); |
| 191 | + DiscardMissizedFaces(detpars_); | |
| 188 | 192 | |
| 189 | 193 | if (multiface) // order faces on increasing distance from left margin |
| 190 | 194 | { | ... | ... |
3rdparty/stasm/stasm/stasm/src/misc.cpp
| ... | ... | @@ -851,6 +851,8 @@ EYAW DegreesAsEyaw( // this determines what model is best for a given yaw |
| 851 | 851 | double yaw, // in: yaw in degrees, negative if left facing |
| 852 | 852 | int nmods) // in |
| 853 | 853 | { |
| 854 | + (void) yaw; | |
| 855 | + (void) nmods; | |
| 854 | 856 | #if MOD_3 || MOD_A || MOD_A_EMU // experimental versions |
| 855 | 857 | CV_Assert(nmods == 3); |
| 856 | 858 | if (yaw < -EYAW_TO_USE_DET45) | ... | ... |
3rdparty/stasm/stasm/stasm/src/startshape.cpp
| ... | ... | @@ -410,6 +410,8 @@ static void TraceEyesMouth( |
| 410 | 410 | Image& face_roi, // out: ROI around face, possibly rotated upright |
| 411 | 411 | DetPar& detpar_roi) // out: detpar wrt to face_roi |
| 412 | 412 | { |
| 413 | + (void) face_roi; | |
| 414 | + (void) detpar_roi; | |
| 413 | 415 | #if TRACE_IMAGES // will be 0 unless debugging (defined in stasm.h) |
| 414 | 416 | |
| 415 | 417 | CImage cimg; cvtColor(face_roi, cimg, CV_GRAY2BGR); // color image | ... | ... |