detectMultiScale in JNI

asked 2013-04-13 11:15:23 -0500

Lee gravatar image

updated 2013-04-13 11:26:32 -0500

hi i tried to use cascade.detectMultiScale(gray, faces, 1.2, 3);in my java native code. But i always get faces empty.

vector<Rect> faces;
std::string str;
GetJStringContent(jenv,cascadeName,str);
cascade.load(str);
 if (cascade.empty())
  LOGD("null");
  Mat gray;
   cvtColor(*pframe, gray, CV_BGR2GRAY);
 cascade.detectMultiScale(gray, faces, 1.2, 3);
 if (faces.empty())
 LOGD("faces empty");

Can i use detectMultiScale function in the native part?any idea why i always get empty faces? thank you in advance

edit retag flag offensive close merge delete