From 4efe903a671b288ac485f2d2a9c9aabf2eb7b199 Mon Sep 17 00:00:00 2001 From: Paul Oliver Date: Fri, 8 Aug 2025 22:31:35 +0200 Subject: Adds libcamera bindings --- hsm-cam/FFI/Cam.hpp | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 hsm-cam/FFI/Cam.hpp (limited to 'hsm-cam/FFI/Cam.hpp') diff --git a/hsm-cam/FFI/Cam.hpp b/hsm-cam/FFI/Cam.hpp new file mode 100644 index 0000000..e59fa1d --- /dev/null +++ b/hsm-cam/FFI/Cam.hpp @@ -0,0 +1,25 @@ +#ifndef CAM_HPP +#define CAM_HPP + +enum Severity { + Attention = 0, + Info = 1, + Trace = 2, +}; + +typedef void (*HsLogger)(enum Severity, const char *); +typedef void (*HsCallback)(int fd); + +#ifdef __cplusplus +extern "C" { +#endif + void register_logger(HsLogger hs_logger); + void register_callback(HsCallback hs_callback); + void initialize_ffi(); + void shutdown_ffi(); + void request_capture(); +#ifdef __cplusplus +} +#endif + +#endif -- cgit v1.2.1