summaryrefslogtreecommitdiffhomepage
path: root/ftnoir_tracker_fd/face-detect.h
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2013-03-22 21:48:28 +0100
committerStanislaw Halik <sthalik@misaki.pl>2013-03-22 21:51:09 +0100
commit4f05cb2af239ca8471b77c9f1d1c32e8c4cd3abc (patch)
tree338d3891b0c7710558aea3820d42af6eedfb0af9 /ftnoir_tracker_fd/face-detect.h
parent4f00c4c74d213a37a4b1a3313e50ce2b4dd51271 (diff)
Remove .bat files, actually finish rename this time
Diffstat (limited to 'ftnoir_tracker_fd/face-detect.h')
-rw-r--r--ftnoir_tracker_fd/face-detect.h39
1 files changed, 39 insertions, 0 deletions
diff --git a/ftnoir_tracker_fd/face-detect.h b/ftnoir_tracker_fd/face-detect.h
new file mode 100644
index 00000000..fc359c53
--- /dev/null
+++ b/ftnoir_tracker_fd/face-detect.h
@@ -0,0 +1,39 @@
+#if defined(_WIN32) || defined(WIN32)
+# ifdef __cplusplus
+# define FDAPI_EXTERN extern "C"
+# else
+# define FDAPI_EXTERN
+# endif
+# define FDAPI(ret) FDAPI_EXTERN __declspec(dllexport) ret __cdecl
+#else
+# define FDAPI(ret) ret
+#endif
+
+struct face_detect_settings {
+ unsigned char magic, quit, newOutput, widgetp;
+ int redetect_ms, camera_id;
+};
+
+struct face_detect;
+FDAPI(struct face_detect*) face_detect_init(const char* eyes_model,
+ const char* nose_model,
+ const char* mouth_model,
+ const char* face_model,
+ int capture_no,
+ struct face_detect_settings* settings);
+FDAPI(void) face_detect_free(struct face_detect *ctx);
+FDAPI(int) face_detect_cycle(struct face_detect *ctx, float *data);
+FDAPI(void) face_detect_zero(struct face_detect *ctx);
+
+FDAPI(unsigned char*) face_detect_video(struct face_detect* ctx);
+
+#define FD_VIDEO_WIDTH 252
+#define FD_VIDEO_HEIGHT 189
+#define FD_MAGIC 0x42
+
+struct face_detect_shm {
+ unsigned char zerop, received;
+ float data[6];
+ unsigned char pixels[FD_VIDEO_WIDTH * FD_VIDEO_HEIGHT * 3];
+ struct face_detect_settings settings;
+};