MCPcopy Create free account
hub / github.com/KAlO2/PerfectShow / NeedMouth

Function NeedMouth

jni/stasm/eyedet.cpp:214–229  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

212}
213
214bool NeedMouth( // true if we need the mouth detector for the given mods
215 const vec_Mod& mods) // in: the ASM model(s)
216{
217 static bool need_mouth = true; // static for efficiency
218 if (need_mouth && mouth_det_g.empty()) // not yet opened?
219 {
220 // we need the eyes if the estart field of any model is ESTART_EYE_AND_MOUTH
221 need_mouth = false;
222 for (int imod = 0; imod < NSIZE(mods); imod++)
223 if (mods[imod]->Estart_() == ESTART_EYE_AND_MOUTH)
224 {
225 need_mouth = true;
226 }
227 }
228 return need_mouth;
229}
230
231// Possibly open OpenCV eye detectors and mouth detector. We say "possibly" because
232// the eye and mouth detectors will actually only be opened if any model in mods

Callers 1

OpenEyeMouthDetectorsFunction · 0.85

Calls 2

NSIZEFunction · 0.85
Estart_Method · 0.80

Tested by

no test coverage detected