New file |
| | |
| | | #ifndef _cpp_face_hpp_ |
| | | #define _cpp_face_hpp_ |
| | | |
| | | #include <vector> |
| | | #include <functional> |
| | | |
| | | using VecFunc = std::vector<std::function<void()> >; |
| | | |
| | | #include "struct.h" |
| | | |
| | | namespace cppface |
| | | { |
| | | class sdkface{ |
| | | public: |
| | | sdkface(); |
| | | ~sdkface(); |
| | | |
| | | public: |
| | | int detector(const int min_faces, const int roll_angles, |
| | | const int threads_max, const int gpu); |
| | | int extractor(const int threads_max, const int gpu); |
| | | int propertizer(const int threads_max); |
| | | |
| | | int tracker(const int width, const int height, |
| | | const int max_faces, const int interval, const int sample_size, |
| | | const int threads_max, const int gpu); |
| | | |
| | | public: |
| | | int detect(const cIMAGE *img, const int chan, void **fpos, int *fcnt); |
| | | int extract(const cFacePos &pos, const cIMAGE *img, const int chan, void **feat, int *featLen); |
| | | float compare(unsigned char *feat1, unsigned char *feat2); |
| | | |
| | | int propertize(const cFacePos &pos, const cIMAGE *img, const int chan, void **res); |
| | | |
| | | int track(const cIMAGE *img, const int chan, void **fInfo, int *fcnt); |
| | | int track_resize(const int w, const int h, const int chan); |
| | | private: |
| | | VecFunc dtors_; |
| | | |
| | | cFacePos *fpos_; |
| | | |
| | | int feature_size_; |
| | | unsigned char *feature_; |
| | | |
| | | cFaceInfo *finfos_; |
| | | |
| | | }; |
| | | } // namespace cppface |
| | | |
| | | |
| | | #endif |