hc
2024-12-19 9370bb92b2d16684ee45cf24e879c93c509162da
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
// Copyright 2019 Fuzhou Rockchip Electronics Co., Ltd. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
 
#ifndef EASYMEDIA_LINK_CONFIG_H_
#define EASYMEDIA_LINK_CONFIG_H_
 
namespace easymedia
{
 
    enum LinkType
    {
        LINK_NONE,
        LINK_VIDEO,
        LINK_AUDIO,
        LINK_PICTURE,
        LINK_NNDATA
    };
 
    typedef struct linkvideo {
        void* buffer_ptr;
        unsigned int buffer_size;
        time_t timestamp;
        int nat_type;
    } linkvideo_s;
 
    typedef struct linkaudio {
        void* buffer_ptr;
        unsigned int buffer_size;
        time_t timestamp;
    } linkaudio_s;
 
    typedef struct linkpicture {
        void* buffer_ptr;
        unsigned int buffer_size;
        int type;
        const char* id;
    } linkpicture_s;
 
    typedef struct linknndata {
        int size;
        time_t timestamp;
        const char* nn_model_name;
        RknnResult* rknn_result;
    } linknndata_s;
 
    typedef struct linkcommon {
        int linktype;
        union {
            linkvideo_s video;
            linkaudio_s audio;
            linkpicture picture;
        };
    } linkcommon_s;
 
} // namespace easymedia
 
#endif // #ifndef EASYMEDIA_FLOW_H_