Skip to content

Commit

Permalink
add:添加SetCacheConfig接口
Browse files Browse the repository at this point in the history
  • Loading branch information
GengGode committed Feb 26, 2024
1 parent 69653f6 commit 59c30a7
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 3 deletions.
11 changes: 11 additions & 0 deletions include/cvAutoTrack.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,14 @@
extern "C"
{
#endif

// #define StructType(type) struct type; \
// typedef struct type* type##_ptr;\
// CVAUTOTRACK_API type##_ptr alloc_##type();\
// CVAUTOTRACK_API void free_##type(type##_ptr ptr);
//
// StructType(cvat_string);
//
// string alloc
struct CVAUTOTRACK_API cvat_string;
typedef struct cvat_string* cvat_string_ptr;
Expand Down Expand Up @@ -174,6 +182,8 @@ extern "C"
/// @return 是否卸载成功
bool CVAUTOTRACK_API UnInitResource();

bool CVAUTOTRACK_API SetCacheConfig(const char* config_file, const char* blocks_dir, const char* config, int config_size);

bool CVAUTOTRACK_API SetCoreCachePath(const char* path);
bool CVAUTOTRACK_API GetCoreCachePath(char* path_buff, int buff_size);

Expand Down Expand Up @@ -376,6 +386,7 @@ struct cvAutoTrack
LibraryHandle lib;
bool bind_call(InitResource);
bool bind_call(UnInitResource);
bool bind_call(SetCacheConfig, const_char_ptr config_file, const_char_ptr blocks_dir, const_char_ptr config, int config_size);
bool bind_call(SetCoreCachePath, const_char_ptr path);
bool bind_call(GetCoreCachePath, char_ptr path_buff, int buff_size);
bool bind_call(SetWorldCenter, double x, double y);
Expand Down
9 changes: 8 additions & 1 deletion source/module.resource.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,11 @@ cvat_resource_t CreateResource()
void DestroyResource(cvat_resource_t resource)
{
cvat_resource::destroy(resource);
}
}

bool SetCacheConfig(const char* config_file, const char* blocks_dir, const char* config, int config_size)
{


return false;
}
2 changes: 1 addition & 1 deletion source/resource/version.ver
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8.2.26
8.2.27
2 changes: 1 addition & 1 deletion source/resource/version_hash.hash
Original file line number Diff line number Diff line change
@@ -1 +1 @@
84aed92
69653f6

0 comments on commit 59c30a7

Please sign in to comment.