aboutsummaryrefslogtreecommitdiff
path: root/hsm-cam/FFI/Cam.hpp
blob: eeea814921423454c48da32439868d9bb9d0b56b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#ifndef CAM_HPP
#define CAM_HPP

#define FRAME_WIDTH (800)
#define FRAME_HEIGHT (600)

enum Severity
{
    Attention = 0,
    Info = 1,
    Trace = 2,
};

typedef void (*HsLogger)(enum Severity, const char *);
typedef void (*HsRequestCallback)();

#ifdef __cplusplus
extern "C"
{
#endif
    void register_logger(HsLogger hs_logger);
    void register_request_callback(HsRequestCallback hs_request_callback);
    void start_camera_manager();
    void stop_camera_manager();
    void acquire_camera();
    void release_camera();
    void allocate_frame_buffer();
    void free_frame_buffer();
    void start_camera();
    void stop_camera();
    void create_request();

    int get_dma_buffer_fd();
    void request_frame();
#ifdef __cplusplus
}
#endif

#endif