NVIDIA DeepStream SDK API Reference

9.2 Release
sources/gst-plugins/gst-nvbufferpool/gstnvbufferpool.h
Go to the documentation of this file.
1 /*
2  * SPDX-FileCopyrightText: Copyright (c) 2012-2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
3  * SPDX-License-Identifier: Apache-2.0
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  */
17 
18 #ifndef _GST_NVM_BUFFER_POOL_H_
19 #define _GST_NVM_BUFFER_POOL_H_
20 
21 #include <gst/gst.h>
22 #include <gst/video/video.h>
23 
24 #ifdef __cplusplus
25 extern "C"
26 {
27 #endif
28 
29 G_BEGIN_DECLS
30 
31 #define GST_TYPE_NVM_BUFFER_POOL \
32  (gst_nvm_buffer_pool_get_type ())
33 #define GST_IS_NVM_BUFFER_POOL(obj) \
34  (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_NVM_BUFFER_POOL))
35 #define GST_IS_NVM_BUFFER_POOL_CLASS(klass) \
36  (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_NVM_BUFFER_POOL))
37 #define GST_NVM_BUFFER_POOL(obj) \
38  (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_NVM_BUFFER_POOL, GstNvmBufferPool))
39 #define GST_NVM_BUFFER_POOL_CLASS(klass) \
40  (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_NVM_BUFFER_POOL, GstNvmBufferPoolClass))
41 #define GST_NVM_BUFFER_POOL_GET_CLASS(obj) \
42  (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_NVM_BUFFER_POOL, GstNvmBufferPoolClass))
43 #define GST_NVM_BUFFER_POOL_GET_PRIVATE(obj) \
44  (G_TYPE_INSTANCE_GET_PRIVATE ((obj), GST_TYPE_NVM_BUFFER_POOL, GstNvmBufferPoolPrivate))
45 
48 typedef struct _GstNvmBufferPoolPrivate GstNvmBufferPoolPrivate;
49 
50 #define GST_NVM_MAX_BUFFERS_ALLOWED 30
51 #define GST_NVM_DEFAULT_BUFFERPOOL_TIMEOUT 100000
52 
53 /* surface allocation flags */
54 #define GST_NVM_ALLOC_VIDEO_SURFACE_FLAG (1 << 0)
55 #define GST_NVM_ALLOC_DECODE_SURFACE_FLAG (1 << 1)
56 #define GST_TYPE_NVDS_MEMORY_TYPE (gst_nvds_memory_get_type ())
57 GType gst_nvds_memory_get_type (void);
58 
59 #define PROP_NVDS_MEMORY_TYPE_INSTALL(gobject_class) \
60 do { \
61  g_object_class_install_property (gobject_class, PROP_NVDS_MEMORY_TYPE, \
62  g_param_spec_enum ("cuda-memory-type", "Type of CUDA memory allocated", \
63  "Type of CUDA Memory to be allocated for output buffers", \
64  GST_TYPE_NVDS_MEMORY_TYPE, \
65  CUDA_DEVICE_MEMORY, \
66  (GParamFlags)(G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS | \
67  GST_PARAM_MUTABLE_READY))); \
68 }while(0)
69 
71 {
72  GstBufferPool bufferpool;
74 };
75 
77 {
78  GstBufferPoolClass parent_class;
79 };
80 
81 GstBufferPool * gst_nvm_buffer_pool_new (void);
82 
83 GType gst_nvm_buffer_pool_get_type (void);
84 
85 G_END_DECLS
86 
87 #ifdef __cplusplus
88 }
89 #endif
90 
91 #endif /* _GST_NVM_BUFFER_POOL_H_ */
_GstNvmBufferPool::bufferpool
GstBufferPool bufferpool
Definition: sources/gst-plugins/gst-nvbufferpool/gstnvbufferpool.h:72
_GstNvmBufferPool
Definition: sources/gst-plugins/gst-nvbufferpool/gstnvbufferpool.h:70
_GstNvmBufferPoolClass
Definition: sources/gst-plugins/gst-nvbufferpool/gstnvbufferpool.h:76
gst_nvm_buffer_pool_new
GstBufferPool * gst_nvm_buffer_pool_new(void)
_GstNvmBufferPoolClass::parent_class
GstBufferPoolClass parent_class
Definition: sources/gst-plugins/gst-nvbufferpool/gstnvbufferpool.h:78
gst_nvm_buffer_pool_get_type
GType gst_nvm_buffer_pool_get_type(void)
GstNvmBufferPoolPrivate
struct _GstNvmBufferPoolPrivate GstNvmBufferPoolPrivate
Definition: sources/gst-plugins/gst-nvbufferpool/gstnvbufferpool.h:48
gst_nvds_memory_get_type
GType gst_nvds_memory_get_type(void)
_GstNvmBufferPool::priv
GstNvmBufferPoolPrivate * priv
Definition: sources/gst-plugins/gst-nvbufferpool/gstnvbufferpool.h:73