Doxygen Book
edge_sink.h
Go to the documentation of this file.
1 /* SPDX-License-Identifier: LGPL-2.1-only */
13 #ifndef __GST_EDGE_SINK_H__
14 #define __GST_EDGE_SINK_H__
15 
16 #include <gst/gst.h>
17 #include <gst/base/gstbasesink.h>
18 #include "edge_common.h"
19 #include <nnstreamer-edge.h>
20 #include "nnstreamer_log.h"
21 #include "nnstreamer_plugin_api.h"
22 #include "tensor_typedef.h"
23 
24 G_BEGIN_DECLS
25 #define GST_TYPE_EDGESINK \
26  (gst_edgesink_get_type())
27 #define GST_EDGESINK(obj) \
28  (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_EDGESINK,GstEdgeSink))
29 #define GST_EDGESINK_CLASS(klass) \
30  (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_EDGESINK,GstEdgeSinkClass))
31 #define GST_IS_EDGESINK(obj) \
32  (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_EDGESINK))
33 #define GST_IS_EDGESINK_CLASS(klass) \
34  (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_EDGESINK))
35 #define GST_EDGESINK_CAST(obj) ((GstEdgeSink *)(obj))
36 typedef struct _GstEdgeSink GstEdgeSink;
38 
43 {
44  GstBaseSink element;
45 
46  gchar *host;
47  guint16 port;
48  gchar *dest_host;
49  guint16 dest_port;
50  gchar *topic;
51 
52  nns_edge_connect_type_e connect_type;
53  nns_edge_h edge_h;
54  gboolean wait_connection;
56 
57  gchar *custom_lib;
58  gboolean is_connected;
59  GMutex lock;
60  GCond cond;
61 };
62 
67 {
68  GstBaseSinkClass parent_class;
69 };
70 
71 GType gst_edgesink_get_type (void);
72 
73 G_END_DECLS
74 #endif /* __GST_EDGE_SINK_H__ */
edge_common.h
Common functions for edge sink and src.
_GstEdgeSink::topic
gchar * topic
Definition: edge_sink.h:50
_GstEdgeSink::edge_h
nns_edge_h edge_h
Definition: edge_sink.h:53
_GstEdgeSink::wait_connection
gboolean wait_connection
Definition: edge_sink.h:54
nnstreamer_log.h
Internal log util for NNStreamer plugins and native APIs.
_GstEdgeSinkClass
GstEdgeSinkClass data structure.
Definition: edge_sink.h:66
gst_edgesink_get_type
GType gst_edgesink_get_type(void)
_GstEdgeSink
GstEdgeSink data structure.
Definition: edge_sink.h:42
_GstEdgeSink::connect_type
nns_edge_connect_type_e connect_type
Definition: edge_sink.h:52
_GstEdgeSink::custom_lib
gchar * custom_lib
Definition: edge_sink.h:57
_GstEdgeSink::dest_host
gchar * dest_host
Definition: edge_sink.h:48
_GstEdgeSinkClass::parent_class
GstBaseSinkClass parent_class
Definition: edge_sink.h:68
tensor_typedef.h
Common header file for NNStreamer, the GStreamer plugin for neural networks.
_GstEdgeSink::dest_port
guint16 dest_port
Definition: edge_sink.h:49
_GstEdgeSink::connection_timeout
guint64 connection_timeout
Definition: edge_sink.h:55
_GstEdgeSink::element
GstBaseSink element
Definition: edge_sink.h:44
_GstEdgeSink::cond
GCond cond
Definition: edge_sink.h:60
_GstEdgeSink::lock
GMutex lock
Definition: edge_sink.h:59
_GstEdgeSink::port
guint16 port
Definition: edge_sink.h:47
_GstEdgeSink::is_connected
gboolean is_connected
Definition: edge_sink.h:58
_GstEdgeSink::host
gchar * host
Definition: edge_sink.h:46
nnstreamer_plugin_api.h
Optional/Additional NNStreamer APIs for sub-plugin writers. (Need Gst devel)