There are several reason for writing custom wrapper instead of using existing solutions (such as EmguCV):
- I need actual version of OpenCV
- I need CUDA support
- I don't need a whole functionality of OpenCV
This method has two input parameters: cv::InputArray and cv::OutputArray
My wrapped method (I expose two detect Überladungen) < /p>
C ++ Seite: < /p>
Code: Select all
extern "C" {
WRAPPEROPENCV_DLL_API void* Create_FaceDetect_DNN(const char* model, const char* config,
cv::Size input_size, float score_threshold, float nms_threshold, int top_k,
int backend_id, int target_id) {
cv::Ptr* faceDetectorYN = new cv::Ptr(
cv::FaceDetectorYN::create(model, config, input_size, score_threshold,
nms_threshold, top_k, backend_id, target_id));
if (faceDetectorYN->empty()) {
std::cerr