From 704ef49f12c00a9b56c1fac6f6e3517ff5436766 Mon Sep 17 00:00:00 2001 From: Jonas Jongejan Date: Sun, 10 Apr 2016 22:10:46 +0200 Subject: [PATCH] getFaceBoundingBoxes fix --- src/ofxFaceTracker2.cpp | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/ofxFaceTracker2.cpp b/src/ofxFaceTracker2.cpp index 2c5b3a8..b6fdde9 100755 --- a/src/ofxFaceTracker2.cpp +++ b/src/ofxFaceTracker2.cpp @@ -292,8 +292,15 @@ int ofxFaceTracker2::size() const { vector ofxFaceTracker2::getFaceBoundingBoxes() const { vector ret; - for(auto rect : facesRects){ - ret.push_back(ofRectangle(rect.left(),rect.top(), rect.width(), rect.height())); + for(int i=0; i i){ + rect = ofRectangle(facesRects[i].left(), + facesRects[i].top(), + facesRects[i].width(), + facesRects[i].height()); + } + ret.push_back(rect); } return ret; }