wx_human_seg 3.0.0
|
Go to the source code of this file.
Classes | |
struct | WXIDPhotoConfig_t |
Typedefs | |
typedef struct WXIDPhotoConfig_t | WXIDPhotoConfig_t |
typedef struct WXIDPhotoSettings_t | WXIDPhotoSettings_t |
typedef enum WXGlassesType_e | WXGlassesType_e |
typedef struct WXIDPhotoPreDetectResult_t | WXIDPhotoPreDetectResult_t |
typedef struct WXIDPhoto_t | WXIDPhoto_t |
Enumerations | |
enum | WXGlassesType_e { NoGlasses = 0 , NormalGlasses = 1 , DarkGlasses = 2 } |
Functions | |
WX_API int | WXIDPhotoSettings_Create (WXIDPhotoSettings_t **settings_p) |
WX_API void | WXIDPhotoSettings_Release (WXIDPhotoSettings_t *settings) |
WX_API void | WXIDPhotoSettings_SetInt (WXIDPhotoSettings_t *settings, const char *key, int value) |
WX_API void | WXIDPhotoSettings_SetFloat (WXIDPhotoSettings_t *settings, const char *key, float value) |
WX_API void | WXIDPhotoSettings_SetBool (WXIDPhotoSettings_t *settings, const char *key, uint8_t value) |
WX_API void | WXIDPhotoSettings_SetString (WXIDPhotoSettings_t *settings, const char *key, const char *str) |
WX_API void | WXIDPhotoSettings_SetIntArray (WXIDPhotoSettings_t *settings, const char *key, const int *arr, int size) |
WX_API void | WXIDPhotoSettings_SetFloatArray (WXIDPhotoSettings_t *settings, const char *key, const float *arr, int size) |
WX_API int | WXIDPhotoSettings_GetInt (WXIDPhotoSettings_t *settings, const char *key, int defValue) |
WX_API float | WXIDPhotoSettings_GetFloat (WXIDPhotoSettings_t *settings, const char *key, float defValue) |
WX_API uint8_t | WXIDPhotoSettings_GetBool (WXIDPhotoSettings_t *settings, const char *key, uint8_t defValue) |
WX_API const char * | WXIDPhotoSettings_GetString (WXIDPhotoSettings_t *settings, const char *key) |
WX_API const int * | WXIDPhotoSettings_GetIntArray (WXIDPhotoSettings_t *settings, const char *key, int *size_p) |
WX_API const float * | WXIDPhotoSettings_GetFloatArray (WXIDPhotoSettings_t *settings, const char *key, int *size_p) |
WX_API int | WXIDPhotoSettings_HasKey (WXIDPhotoSettings_t *settings, const char *key) |
WX_API void | WXIDPhotoPreDetectResult_Release (WXIDPhotoPreDetectResult_t *result) |
WX_API int | WXIDPhotoPreDetectResult_GetInt (WXIDPhotoPreDetectResult_t *result, const char *key, int defValue) |
WX_API const float * | WXIDPhotoPreDetectResult_GetFloatArray (WXIDPhotoPreDetectResult_t *result, const char *key) |
WX_API int | WXIDPhoto_Create (WXDeviceType deviceType, WXIDPhoto_t **idphoto_p) |
WX_API void | WXIDPhoto_Release (WXIDPhoto_t *p) |
WX_API int | WXIDPhoto_MakeIDPhoto (WXIDPhoto_t *idphoto, const WXImage_t *inImg, const WXIDPhotoConfig_t *config, const WXIDPhotoPreDetectResult_t *preResult, WXImage_t **result_img_p) |
WX_API int | WXIDPhoto_PreDetect (WXIDPhoto_t *idphoto, const WXImage_t *inImg, WXIDPhotoPreDetectResult_t **result_p) |
WX_API void | WXIDPhoto_SetSettings (WXIDPhoto_t *idphoto, const WXIDPhotoSettings_t *settings) |
证件照sdk接口,证件照制作和环境检测接口
typedef enum WXGlassesType_e WXGlassesType_e |
佩戴眼镜类型
typedef struct WXIDPhoto_t WXIDPhoto_t |
WXIDPhoto_t 证件照制作和预检测句柄类型
typedef struct WXIDPhotoConfig_t WXIDPhotoConfig_t |
证件照制作参数配置 具体说明参考 wonxai::WXIDPhotoConfig
typedef struct WXIDPhotoPreDetectResult_t WXIDPhotoPreDetectResult_t |
WXIDPhotoPreDetectResult_t
WXIDPhotoPreDetectResult_t可用key值和类型:
key list: face_count int, up_empty int, right_empty, int bottom_empty, int, left_empty, int size_score, int darkillum, int face_blur, int face_unbalance, int glasses, int(GlassesType_e) eyes_close, int mouth_close, int face_occlusion, int head_pose, floatArray gaze, int
typedef struct WXIDPhotoSettings_t WXIDPhotoSettings_t |
WXIDPhotoSettings_t
enum WXGlassesType_e |
WX_API int WXIDPhoto_Create | ( | WXDeviceType | deviceType, |
WXIDPhoto_t ** | idphoto_p | ||
) |
创建WXIDPhoto_t对象
[in] | deviceType | 是否使用gpu |
[out] | idphoto_p | 创建并返回WXIDPhoto_t对象 |
WX_API int WXIDPhoto_MakeIDPhoto | ( | WXIDPhoto_t * | idphoto, |
const WXImage_t * | inImg, | ||
const WXIDPhotoConfig_t * | config, | ||
const WXIDPhotoPreDetectResult_t * | preResult, | ||
WXImage_t ** | result_img_p | ||
) |
证件照制作接口
[in] | idphoto | WXIDPhoto_t对象,由 WXIDPhoto_Create 函数创造 |
[in] | inImg | 待制作原图 |
[in] | config | 制作配置 |
[in] | preResult | 环境检测结果,可以设置为NULL |
[out] | result_img_p | 制作好的证件照结果图 |
成功 - 0 失败 - 错误码
WX_API int WXIDPhoto_PreDetect | ( | WXIDPhoto_t * | idphoto, |
const WXImage_t * | inImg, | ||
WXIDPhotoPreDetectResult_t ** | result_p | ||
) |
证件照环境检测
[in] | idphoto | WXIDPhoto_t对象,由 WXIDPhoto_Create 函数创造 |
[in] | inImg | 待检测的原图 |
[out] | result_p | 检测结果 WXIDPhotoPreDetectResult_t |
成功 - 0 失败 - 错误码
WX_API void WXIDPhoto_Release | ( | WXIDPhoto_t * | p | ) |
释放WXIDPhoto_t对象
WX_API void WXIDPhoto_SetSettings | ( | WXIDPhoto_t * | idphoto, |
const WXIDPhotoSettings_t * | settings | ||
) |
证件照制作和环境检测配置参数, 一般用不到本接口
WX_API const float * WXIDPhotoPreDetectResult_GetFloatArray | ( | WXIDPhotoPreDetectResult_t * | result, |
const char * | key | ||
) |
从WXIDPhotoPreDetectResult_t对象中获取浮点数组值, 如果不存在key值,返回NULL
WX_API int WXIDPhotoPreDetectResult_GetInt | ( | WXIDPhotoPreDetectResult_t * | result, |
const char * | key, | ||
int | defValue | ||
) |
从WXIDPhotoPreDetectResult_t对象中获取整形值, 如果不存在key值,返回defValue
WX_API void WXIDPhotoPreDetectResult_Release | ( | WXIDPhotoPreDetectResult_t * | result | ) |
释放WXIDPhotoPreDetectResult_t对象
WX_API int WXIDPhotoSettings_Create | ( | WXIDPhotoSettings_t ** | settings_p | ) |
创建一个WXIDPhotoSettings_t对象
WX_API uint8_t WXIDPhotoSettings_GetBool | ( | WXIDPhotoSettings_t * | settings, |
const char * | key, | ||
uint8_t | defValue | ||
) |
获取WXIDPhotoSettings_t中的布尔值,
WX_API float WXIDPhotoSettings_GetFloat | ( | WXIDPhotoSettings_t * | settings, |
const char * | key, | ||
float | defValue | ||
) |
获取WXIDPhotoSettings_t中的浮点值,
WX_API const float * WXIDPhotoSettings_GetFloatArray | ( | WXIDPhotoSettings_t * | settings, |
const char * | key, | ||
int * | size_p | ||
) |
获取WXIDPhotoSettings_t中的浮点数组值, 不存在key,则返回NULL,
WX_API int WXIDPhotoSettings_GetInt | ( | WXIDPhotoSettings_t * | settings, |
const char * | key, | ||
int | defValue | ||
) |
获取WXIDPhotoSettings_t中的整形值,
WX_API const int * WXIDPhotoSettings_GetIntArray | ( | WXIDPhotoSettings_t * | settings, |
const char * | key, | ||
int * | size_p | ||
) |
获取WXIDPhotoSettings_t中的整型数组值, 不存在key,则返回NULL,
WX_API const char * WXIDPhotoSettings_GetString | ( | WXIDPhotoSettings_t * | settings, |
const char * | key | ||
) |
获取WXIDPhotoSettings_t中的字符串值, 不存在key,则返回NULL,
WX_API int WXIDPhotoSettings_HasKey | ( | WXIDPhotoSettings_t * | settings, |
const char * | key | ||
) |
判断是否存在key,
WX_API void WXIDPhotoSettings_Release | ( | WXIDPhotoSettings_t * | settings | ) |
释放一个WXIDPhotoSettings_t对象
WX_API void WXIDPhotoSettings_SetBool | ( | WXIDPhotoSettings_t * | settings, |
const char * | key, | ||
uint8_t | value | ||
) |
为WXIDPhotoSettings_t设置值,
WX_API void WXIDPhotoSettings_SetFloat | ( | WXIDPhotoSettings_t * | settings, |
const char * | key, | ||
float | value | ||
) |
为WXIDPhotoSettings_t设置值,
WX_API void WXIDPhotoSettings_SetFloatArray | ( | WXIDPhotoSettings_t * | settings, |
const char * | key, | ||
const float * | arr, | ||
int | size | ||
) |
为WXIDPhotoSettings_t设置值,
WX_API void WXIDPhotoSettings_SetInt | ( | WXIDPhotoSettings_t * | settings, |
const char * | key, | ||
int | value | ||
) |
为WXIDPhotoSettings_t设置值,
WX_API void WXIDPhotoSettings_SetIntArray | ( | WXIDPhotoSettings_t * | settings, |
const char * | key, | ||
const int * | arr, | ||
int | size | ||
) |
为WXIDPhotoSettings_t设置值,
WX_API void WXIDPhotoSettings_SetString | ( | WXIDPhotoSettings_t * | settings, |
const char * | key, | ||
const char * | str | ||
) |
为WXIDPhotoSettings_t设置值,