From cc6f8a873c7efd28fbbeb7c1c70b28a053586f17 Mon Sep 17 00:00:00 2001 From: suntianyu <xuepengqiang@aiotlink.com> Date: 星期五, 30 七月 2021 10:53:09 +0800 Subject: [PATCH] m --- lib/h_interface.cpp | 30 +++++++++++++++++++++++++----- 1 files changed, 25 insertions(+), 5 deletions(-) diff --git a/lib/h_interface.cpp b/lib/h_interface.cpp index a9ca2ce..d612f60 100644 --- a/lib/h_interface.cpp +++ b/lib/h_interface.cpp @@ -11,7 +11,7 @@ int m_staticStruct::times = 10; // 鍒涘缓 -YOLOTRACK_API void* create(const char *conf, int *max_chan) +API void* create(const char *conf, int *max_chan) { CLog::Initialize("/opt/vasystem/bin/models/humanCount/log.properties"); AriManager *handle = new AriManager(); @@ -20,17 +20,18 @@ } // 鍘熸煡鎵剧粨鏋滄帴鍙� -YOLOTRACK_API void* get_result(void *handle, const void *img, const int chan) +API void* get_result(void *handle, const void *img, const int chan) { AriManager *h = (AriManager*)handle; TResult *t_result = (TResult*)malloc(sizeof(TResult)); init_TResult(t_result); + DEBUG( "------error "); // h->doInfer(*t_result); return t_result; } // 浼犻�掍汉鑴哥粨鏋滃苟鏌ユ壘淇℃伅 -YOLOTRACK_API void* get_result_face(void *handle, const void *img, const char* arg_json, const int arg_len, void *face_info, const int face_info_size) +API void* get_result_face(void *handle, const void *img, const char* arg_json, const int arg_len, void *face_info, const int face_info_size) { Json::Reader reader; Json::Value root; @@ -45,7 +46,7 @@ return t_result; } -YOLOTRACK_API void release_result(void *res) +API void release_result(void *res) { if (!res) return; TResult *cres = (TResult*)res; @@ -60,7 +61,7 @@ free(cres); } -YOLOTRACK_API void release(void* handle) +API void release(void* handle) { AriManager *h = (AriManager*)handle; delete h; @@ -97,3 +98,22 @@ t->count = 0; t->targets = nullptr; } + + +API int set_data(void* handle, const char *data, const int len, const int type) +{ + return 1; +} + +API int op_channel(void *handle, const char *chan_json, const int json_len, const int op) +{ + return 1; +} + + +//璁剧疆鍥炶皟鍑芥暟淇℃伅 +API int set_cb(void* handle, fn FUNC, void *args) +{ + return 1; +} + -- Gitblit v1.8.0