NVIDIA DeepStream SDK API Reference

7.0 Release
gstnvstreammux.h
Go to the documentation of this file.
1 /*
2  * SPDX-FileCopyrightText: Copyright (c) 2021-2023 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
3  * SPDX-License-Identifier: LicenseRef-NvidiaProprietary
4  *
5  * NVIDIA CORPORATION, its affiliates and licensors retain all intellectual
6  * property and proprietary rights in and to this material, related
7  * documentation and any modifications thereto. Any use, reproduction,
8  * disclosure or distribution of this material and related documentation
9  * without an express license agreement from NVIDIA CORPORATION or
10  * its affiliates is strictly prohibited.
11  */
12 
13 #ifndef __GST_NVSTREAMMUX_H__
14 #define __GST_NVSTREAMMUX_H__
15 
16 #include <gst/gst.h>
17 #include <gst/video/video.h>
18 #include <time.h>
19 #include "cuda_runtime_api.h"
20 #include "nvstreammux_debug.h"
21 #include "nvstreammux.h"
22 #include "GstNvStreamMuxCtx.h"
23 #include "gstnvstreammux_ntp.h"
24 #include "gstnvtimesynch.h"
25 #include "gstnvstreammuxdebug.h"
26 
27 G_BEGIN_DECLS
28 #define GST_TYPE_NVSTREAMMUX \
29  (gst_nvstreammux_2_get_type ())
30 #define GST_NVSTREAMMUX(obj) \
31  (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_NVSTREAMMUX,GstNvStreamMux))
32 #define GST_NVSTREAMMUX_CLASS(klass) \
33  (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_NVSTREAMMUX,GstNvStreamMuxClass))
34 #define GST_IS_NVSTREAMMUX(obj) \
35  (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_NVSTREAMMUX))
36 #define GST_IS_NVSTREAMMUX_CLASS(klass) \
37  (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_NVSTREAMMUX))
40 #define NEW_METADATA 1
41 
43 {
44  GstElement element;
45 
46  GstPad *srcpad;
47 
48 
49  GstSegment segment;
50 
51  GstFlowReturn last_flow_ret;
52 
53  unsigned int width;
54 
55  unsigned int height;
56 
58 
59  bool send_eos;
60 
61  bool eos_sent;
62 
64 
65  gboolean query_resolution;
66 
67  unsigned int batch_size;
69 
70  GstVideoInfo out_videoinfo;
71 
72  unsigned int num_surfaces_per_frame;
73 
75 
77 
78  gulong cur_frame_pts;
79  GstClockTime pts_offset;
80 
85 
88 
90 
91  gboolean segment_sent;
92 
94 
96  gboolean isAudio;
97 
100 
102  gboolean sys_ts;
104  GHashTable *sink_pad_caps;
105 
107  gboolean sync_inputs;
108 
109  GstClockTime max_latency;
110 
111  GstClockTime prev_outbuf_pts;
112 
114 
115  GstClockTime peer_latency_min;
116  GstClockTime peer_latency_max;
119  GMutex ctx_lock;
120 
124  GstClockTime frame_duration;
126  gboolean no_pipeline_eos;
127 
129 };
130 
132 {
133  GstElementClass parent_class;
134 };
135 
136 G_GNUC_INTERNAL GType gst_nvstreammux_2_get_type (void);
137 
138 G_END_DECLS
139 #endif
_GstNvStreamMux::all_pads_eos
bool all_pads_eos
Definition: gstnvstreammux.h:63
_GstNvStreamMux::out_videoinfo
GstVideoInfo out_videoinfo
Definition: gstnvstreammux.h:70
_GstNvStreamMux
Definition: gstnvstreammux.h:42
_GstNvStreamMux::sys_ts
gboolean sys_ts
property that specifies if the ntp timestamp is from rtspsrc or system
Definition: gstnvstreammux.h:102
_GstNvStreamMux::width
unsigned int width
Definition: gstnvstreammux.h:53
_GstNvStreamMux::send_eos
bool send_eos
Definition: gstnvstreammux.h:59
_GstNvStreamMux::segment
GstSegment segment
Definition: gstnvstreammux.h:49
_GstNvStreamMux::num_surfaces_per_frame
unsigned int num_surfaces_per_frame
Definition: gstnvstreammux.h:72
_GstNvStreamMux::synch_buffer
NvTimeSync * synch_buffer
Definition: gstnvstreammux.h:113
_GstNvStreamMux::frame_num_reset_on_stream_reset
gboolean frame_num_reset_on_stream_reset
Definition: gstnvstreammux.h:122
nvstreammux.h
_GstNvStreamMux::segment_sent
gboolean segment_sent
Definition: gstnvstreammux.h:91
gst_nvstreammux_2_get_type
G_GNUC_INTERNAL GType gst_nvstreammux_2_get_type(void)
_GstNvStreamMux::peer_latency_min
GstClockTime peer_latency_min
Definition: gstnvstreammux.h:115
_GstNvStreamMux::sync_inputs
gboolean sync_inputs
whether input buffer synchronization is turned ON/OFF
Definition: gstnvstreammux.h:107
_GstNvStreamMux::config_file_path
gchar * config_file_path
Path to the configuration file for this instance of gst-nvstreammux.
Definition: gstnvstreammux.h:82
_GstNvStreamMux::num_sink_pads
guint num_sink_pads
Definition: gstnvstreammux.h:93
gstnvtimesynch.h
GstNvStreamMuxCtx.h
StreamMux heler context class.
gstnvstreammuxdebug.h
_GstNvStreamMux::frame_duration_nsec
gulong frame_duration_nsec
Definition: gstnvstreammux.h:76
_GstNvStreamMux::pad_task_created
bool pad_task_created
Definition: gstnvstreammux.h:74
_GstNvStreamMux::prev_outbuf_pts
GstClockTime prev_outbuf_pts
Definition: gstnvstreammux.h:111
_GstNvStreamMux::srcpad
GstPad * srcpad
Definition: gstnvstreammux.h:46
_GstNvStreamMux::peer_latency_live
gboolean peer_latency_live
Definition: gstnvstreammux.h:117
_GstNvStreamMux::cur_frame_pts
gulong cur_frame_pts
Definition: gstnvstreammux.h:78
_GstNvStreamMux::eos_sent
bool eos_sent
Definition: gstnvstreammux.h:61
_GstNvStreamMux::has_peer_latency
gboolean has_peer_latency
Definition: gstnvstreammux.h:118
_GstNvStreamMux::ctx_lock
GMutex ctx_lock
Definition: gstnvstreammux.h:119
_GstNvStreamMux::timeout_usec
gint timeout_usec
Definition: gstnvstreammux.h:68
GstNvStreamMuxCtx
Definition: GstNvStreamMuxCtx.h:27
_GstNvStreamMux::query_resolution
gboolean query_resolution
Definition: gstnvstreammux.h:65
GstNvDsNtpCalculatorMode
GstNvDsNtpCalculatorMode
Definition: gstnvstreammux_ntp.h:25
_GstNvStreamMux::element
GstElement element
Definition: gstnvstreammux.h:44
_GstNvStreamMux::pts_offset
GstClockTime pts_offset
Definition: gstnvstreammux.h:79
nvstreammux_debug.h
_GstNvStreamMux::frame_num_reset_on_eos
gboolean frame_num_reset_on_eos
Definition: gstnvstreammux.h:121
_GstNvStreamMux::module_initialized
gboolean module_initialized
Definition: gstnvstreammux.h:89
_GstNvStreamMux::height
unsigned int height
Definition: gstnvstreammux.h:55
_GstNvStreamMux::max_latency
GstClockTime max_latency
Definition: gstnvstreammux.h:109
_GstNvStreamMux::debug_iface
INvStreammuxDebug * debug_iface
Definition: gstnvstreammux.h:128
_GstNvStreamMux::config_file_available
gboolean config_file_available
boolean TRUE if a new config_file_path setting is available
Definition: gstnvstreammux.h:84
NvStreamMux
Definition: nvstreammux.h:45
_GstNvStreamMux::muxCtx
GstNvStreamMuxCtx * muxCtx
muxer context
Definition: gstnvstreammux.h:99
_GstNvStreamMux::no_pipeline_eos
gboolean no_pipeline_eos
Definition: gstnvstreammux.h:126
_GstNvStreamMux::helper
NvStreamMux * helper
Definition: gstnvstreammux.h:57
_GstNvStreamMux::frame_duration
GstClockTime frame_duration
Application specified frame duration used for NTP timestamp calculaion.
Definition: gstnvstreammux.h:124
_GstNvStreamMux::ntp_calc_mode
GstNvDsNtpCalculatorMode ntp_calc_mode
Definition: gstnvstreammux.h:103
_GstNvStreamMuxClass
Definition: gstnvstreammux.h:131
gstnvstreammux_ntp.h
_GstNvStreamMux::pushed_stream_start_once
bool pushed_stream_start_once
Definition: gstnvstreammux.h:125
_GstNvStreamMux::peer_latency_max
GstClockTime peer_latency_max
Definition: gstnvstreammux.h:116
_GstNvStreamMux::last_flow_ret
GstFlowReturn last_flow_ret
Definition: gstnvstreammux.h:51
_GstNvStreamMuxClass::parent_class
GstElementClass parent_class
Definition: gstnvstreammux.h:133
NvTimeSync
Definition: gstnvtimesynch.h:23
_GstNvStreamMux::isAudio
gboolean isAudio
Audio support.
Definition: gstnvstreammux.h:96
_GstNvStreamMux::config_file_parse_successful
gboolean config_file_parse_successful
Boolean indicating if the config parsing was successful.
Definition: gstnvstreammux.h:87
_GstNvStreamMux::batch_size
unsigned int batch_size
Definition: gstnvstreammux.h:67
INvStreammuxDebug
Definition: nvstreammux_debug.h:16
_GstNvStreamMux::sink_pad_caps
GHashTable * sink_pad_caps
Definition: gstnvstreammux.h:104