영상처리
조회수 : 4
윈도우_opencv_빌드   ( 48/52 )
example.cpp 소스 파일 (6/8) 1.            drawContours(right_side, vector<vector<Point>>{*largest_contour}, -1, Scalar(255, 255, 255), FILLED);2.            drawContours(right_side, vector<vector<Point>>{*largest_contour}, -1, Scalar(0, 255, 0), 2);3.            vector<int> hull;4.            convexHull(*largest_contour, hull, false);5.            vector<Vec4i> defects;6.            if (hull.size() > 3) {7.                convexityDefects(*largest_contour, hull, defects);8.                fingerCount = countFingers(*largest_contour, defects);9.                gesture = recognizeGesture(fingerCount);10.            }11.        }12.        if (frame_count % 10 == 0) {13.            auto end = chrono::high_resolution_clock::now();14.            chrono::duration<float> duration = end - start;15.            fps = frame_count / duration.count();16.        }