NUGU SDK Linux  1.7.6
nugu_audio.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2019 SK Telecom Co., Ltd. All rights reserved.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #ifndef __NUGU_AUDIO_H__
18 #define __NUGU_AUDIO_H__
19 
20 #include <nugu.h>
21 
22 #ifdef __cplusplus
23 extern "C" {
24 #endif
25 
30 #define NUGU_AUDIO_ATTRIBUTE_MUSIC_DEFAULT_STRING "MUSIC"
31 #define NUGU_AUDIO_ATTRIBUTE_RINGTONE_DEFAULT_STRING "RINGTONE"
32 #define NUGU_AUDIO_ATTRIBUTE_CALL_DEFAULT_STRING "CALL"
33 #define NUGU_AUDIO_ATTRIBUTE_NOTIFICATION_DEFAULT_STRING "NOTIFICATION"
34 #define NUGU_AUDIO_ATTRIBUTE_ALARM_DEFAULT_STRING "ALARM"
35 #define NUGU_AUDIO_ATTRIBUTE_VOICE_COMMAND_DEFAULT_STRING "VOICE_COMMAND"
36 #define NUGU_AUDIO_ATTRIBUTE_NAVIGATION_DEFAULT_STRING "NAVIGATION"
37 #define NUGU_AUDIO_ATTRIBUTE_SYSTEM_SOUND_DEFAULT_STRING "SYSTEM_SOUND"
38 
48  NUGU_AUDIO_SAMPLE_RATE_MAX
49 };
50 
69  NUGU_AUDIO_FORMAT_MAX
70 };
71 
87 };
88 
93  enum nugu_audio_sample_rate samplerate;
94  enum nugu_audio_format format;
95  int channel;
96 };
97 
102 
107 
113 NUGU_API void nugu_audio_set_attribute_str(const NuguAudioAttribute attribute,
114  const char *str);
115 
121 NUGU_API const char *
123 
130 
131 #ifdef __cplusplus
132 }
133 #endif
134 
135 #endif
nugu_audio_attribute
audio attribute
Definition: nugu_audio.h:75
@ NUGU_AUDIO_ATTRIBUTE_NAVIGATION
Definition: nugu_audio.h:84
@ NUGU_AUDIO_ATTRIBUTE_MUSIC
Definition: nugu_audio.h:76
@ NUGU_AUDIO_ATTRIBUTE_NOTIFICATION
Definition: nugu_audio.h:79
@ NUGU_AUDIO_ATTRIBUTE_CALL
Definition: nugu_audio.h:78
@ NUGU_AUDIO_ATTRIBUTE_RINGTONE
Definition: nugu_audio.h:77
@ NUGU_AUDIO_ATTRIBUTE_ALARM
Definition: nugu_audio.h:81
@ NUGU_AUDIO_ATTRIBUTE_SYSTEM_SOUND
Definition: nugu_audio.h:85
@ NUGU_AUDIO_ATTRIBUTE_VOICE_COMMAND
Definition: nugu_audio.h:82
nugu_audio_sample_rate
audio sample rate
Definition: nugu_audio.h:42
@ NUGU_AUDIO_SAMPLE_RATE_44K
Definition: nugu_audio.h:47
@ NUGU_AUDIO_SAMPLE_RATE_16K
Definition: nugu_audio.h:44
@ NUGU_AUDIO_SAMPLE_RATE_22K
Definition: nugu_audio.h:46
@ NUGU_AUDIO_SAMPLE_RATE_8K
Definition: nugu_audio.h:43
@ NUGU_AUDIO_SAMPLE_RATE_32K
Definition: nugu_audio.h:45
NUGU_API const char * nugu_audio_get_attribute_str(const NuguAudioAttribute attribute)
Get audio attribute string.
enum nugu_audio_attribute NuguAudioAttribute
NuguAudioAttribute.
Definition: nugu_audio.h:101
nugu_audio_format
audio format
Definition: nugu_audio.h:54
@ NUGU_AUDIO_FORMAT_U24_LE
Definition: nugu_audio.h:63
@ NUGU_AUDIO_FORMAT_U32_BE
Definition: nugu_audio.h:68
@ NUGU_AUDIO_FORMAT_U16_BE
Definition: nugu_audio.h:60
@ NUGU_AUDIO_FORMAT_S24_LE
Definition: nugu_audio.h:61
@ NUGU_AUDIO_FORMAT_U24_BE
Definition: nugu_audio.h:64
@ NUGU_AUDIO_FORMAT_S24_BE
Definition: nugu_audio.h:62
@ NUGU_AUDIO_FORMAT_U32_LE
Definition: nugu_audio.h:67
@ NUGU_AUDIO_FORMAT_U16_LE
Definition: nugu_audio.h:59
@ NUGU_AUDIO_FORMAT_S32_LE
Definition: nugu_audio.h:65
@ NUGU_AUDIO_FORMAT_S16_BE
Definition: nugu_audio.h:58
@ NUGU_AUDIO_FORMAT_U8
Definition: nugu_audio.h:56
@ NUGU_AUDIO_FORMAT_S8
Definition: nugu_audio.h:55
@ NUGU_AUDIO_FORMAT_S16_LE
Definition: nugu_audio.h:57
@ NUGU_AUDIO_FORMAT_S32_BE
Definition: nugu_audio.h:66
NUGU_API void nugu_audio_set_attribute_str(const NuguAudioAttribute attribute, const char *str)
Set audio attribute string.
NUGU_API NuguAudioAttribute nugu_audio_get_attribute(const char *str)
Get audio attribute type from string.
audio property
Definition: nugu_audio.h:92