NVIDIA DeepStream SDK API Reference
9.0 Release
9.0/sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h
Go to the documentation of this file.
1
/*
2
* SPDX-FileCopyrightText: Copyright (c) 2020-2022 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 __DEEPSTREAM_ASR_APP_H_
14
#define __DEEPSTREAM_ASR_APP_H_
15
16
#include <gst/gst.h>
17
#include <glib.h>
18
#include <stdio.h>
19
#include <stdlib.h>
20
#include "
deepstream_asr_config_file_parser.h
"
21
22
#define CHECK_PTR(ptr) \
23
if(ptr == NULL) \
24
{ \
25
return -1; \
26
}
27
28
typedef
struct
__StreamCtx
29
{
30
gchar *
uri
;
31
guint
stream_id
;
32
guint
has_audio
;
33
guint
bus_id
;
34
GstElement *
asr_pipeline
;
35
int
eos_received
;
36
NvDsAudioConfig
audio_config
;
37
FILE *
FP_asr
;
38
}
StreamCtx
;
39
40
typedef
struct
__AppCtx
41
{
42
guint
num_sources
;
43
StreamCtx
*
sctx
;
44
NvDsAppConfig
app_config
;
45
}
AppCtx
;
46
47
48
int
create_pipeline
(
AppCtx
*appctx,
int
stream_num,
StreamCtx
*sctx);
49
int
start_pipeline
(
int
stream_num,
StreamCtx
*sctx);
50
int
destroy_pipeline
(
StreamCtx
*sctx);
51
52
guint
get_num_sources
(gchar *cfg_file_path);
53
gboolean
parse_config_file
(
AppCtx
*appctx, gchar *config_file);
54
55
G_BEGIN_DECLS
56
57
guint
get_num_sources_yaml
(gchar *cfg_file_path);
58
gboolean
parse_config_file_yaml
(
AppCtx
*appctx, gchar *config_file);
59
60
G_END_DECLS
61
#endif
__AppCtx::app_config
NvDsAppConfig app_config
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h:44
__StreamCtx::asr_pipeline
GstElement * asr_pipeline
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h:34
AppCtx
REST server application context.
Definition:
sources/includes/nvds_appctx_server.h:46
__AppCtx::num_sources
guint num_sources
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h:42
__StreamCtx::eos_received
int eos_received
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h:35
__StreamCtx::stream_id
guint stream_id
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h:31
__StreamCtx
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h:28
start_pipeline
int start_pipeline(int stream_num, StreamCtx *sctx)
__StreamCtx::FP_asr
FILE * FP_asr
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h:37
__NvDsAppConfig
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_config_file_parser.h:27
__StreamCtx::bus_id
guint bus_id
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h:33
__NvDsAudioConfig
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_config_file_parser.h:19
destroy_pipeline
int destroy_pipeline(StreamCtx *sctx)
__AppCtx::sctx
StreamCtx * sctx
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h:43
AppCtx
struct __AppCtx AppCtx
__StreamCtx::audio_config
NvDsAudioConfig audio_config
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h:36
create_pipeline
int create_pipeline(AppCtx *appctx, int stream_num, StreamCtx *sctx)
__StreamCtx::uri
gchar * uri
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h:30
StreamCtx
struct __StreamCtx StreamCtx
__StreamCtx::has_audio
guint has_audio
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h:32
deepstream_asr_config_file_parser.h
__AppCtx
Definition:
sources/apps/audio_apps/deepstream_asr_app/deepstream_asr_app.h:40
get_num_sources_yaml
G_BEGIN_DECLS guint get_num_sources_yaml(gchar *cfg_file_path)
get_num_sources
guint get_num_sources(gchar *cfg_file_path)
parse_config_file
gboolean parse_config_file(AppCtx *appctx, gchar *config_file)
parse_config_file_yaml
gboolean parse_config_file_yaml(AppCtx *appctx, gchar *config_file)
Privacy Policy
|
Manage My Privacy
|
Do Not Sell or Share My Data
|
Terms of Service
|
Accessibility
|
Corporate Policies
|
Product Security
|
Contact
© 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
NVIDIA Confidential | Subject to Change | For test and development only.
Fri Mar 20 2026 14:36:58 | PR-09318-R32