From f757a27218a09fd24a852f34b6490d32fe237017 Mon Sep 17 00:00:00 2001 From: houxiao <houxiao@454eff88-639b-444f-9e54-f578c98de674> Date: 星期五, 21 四月 2017 14:47:55 +0800 Subject: [PATCH] dev --- FaceServer/STFaceCache.h | 20 ++++++++++---------- 1 files changed, 10 insertions(+), 10 deletions(-) diff --git a/FaceServer/STFaceCache.h b/FaceServer/STFaceCache.h index 2c37ca0..3f234ac 100644 --- a/FaceServer/STFaceCache.h +++ b/FaceServer/STFaceCache.h @@ -4,15 +4,7 @@ #include <string> #include "face_daemon_proto.h" -struct STFaceImage -{ - int32_t db_id; - int16_t mb_type; // MB_Frame::MBFType - int16_t width; - int16_t height; - uint32_t size; - const uint8_t* buff; -}; +struct STFaceImage; class STFaceCache { @@ -20,13 +12,21 @@ STFaceCache(const std::string& _stfacedbPath); ~STFaceCache(); + bool init(); + void finit(); + bool load_dbs(); + void close_dbs(); FDP_FaceDetectResult detect(const STFaceImage& img); - FDP_FaceDetectResult save(const STFaceImage& img); + FDP_FaceDetectResult add(const STFaceImage& img); + + //#todo need a delete img, if business not linked faceid and its personid + // they can delete it and save/find again! private: const std::string stfacedbPath; const std::string stfaceModels; + void* _dbContext; void* _cacheContext; }; -- Gitblit v1.8.0