- Timestamp:
- Mar 27, 2015 8:47:20 AM (10 years ago)
- Location:
- pjproject/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjmedia/src/pjmedia-audiodev/bdimad_dev.c
r4748 r5037 5 5 Author: bdSound Development Team (techsupport@bdsound.com) 6 6 7 Date: 30/10/20128 Version 1.0.2069 10 Copyright (c) 201 2bdSound s.r.l. (www.bdsound.com)7 Date: 12/03/2015 8 Version 2.0.0 rev.1618 9 10 Copyright (c) 2015 bdSound s.r.l. (www.bdsound.com) 11 11 All Rights Reserved. 12 12 … … 37 37 /* Only mono mode */ 38 38 #define BD_IMAD_MAX_CHANNELS 1 39 /* Frequency default value (admitted 8000 Hz, 16000 Hz, 32000 Hz and 48000Hz) */39 /* Frequency default value (admitted 8000 Hz, 16000 Hz, 32000 Hz, 44100 Hz and 48000 Hz) */ 40 40 #define BD_IMAD_DEFAULT_FREQ 48000 41 41 /* Default milliseconds per buffer */ … … 46 46 #define BD_IMAD_STARTING_OUTPUT_VOLUME 100 47 47 /* Diagnostic Enable/Disable */ 48 #define BD_IMAD_DIAGNOSTIC BD_IMAD_DIAGNOSTIC_DISABLE 48 #define BD_IMAD_DIAGNOSTIC BD_IMAD_DIAGNOSTIC_DISABLE 49 49 50 50 /* Diagnostic folder path */ 51 wchar_t * bdImadPjDiagnosticFolderPath = L""; 51 #define BD_IMAD_DIAGNOSTIC_PATH "/mnt/sdcard/MUSIC/" 52 53 static wchar_t bdImadPjDiagnosticFolderPath[200]; 52 54 53 55 #define THIS_FILE "bdimad_dev.c" … … 303 305 for(i=0;i<captureDeviceCount;i++) { 304 306 wf->dev_info[i].deviceId = i; 305 wf->dev_info[i].info.caps = PJMEDIA_AUD_DEV_CAP_INPUT_VOLUME_SETTING | 306 PJMEDIA_AUD_DEV_CAP_EC; 307 bdIMADpj_getDeviceCapabilities(BD_IMAD_CAPTURE_DEVICES,&wf->dev_info[i].info.caps); 307 308 wf->dev_info[i].info.default_samples_per_sec = BD_IMAD_DEFAULT_FREQ; 308 309 strcpy(wf->dev_info[i].info.driver, "BD_IMAD"); … … 318 319 for(i=0;i<playbackDeviceCount;i++) { 319 320 wf->dev_info[captureDeviceCount+i].deviceId = captureDeviceCount+i; 320 wf->dev_info[captureDeviceCount+i].info.caps = 321 PJMEDIA_AUD_DEV_CAP_OUTPUT_VOLUME_SETTING | PJMEDIA_AUD_DEV_CAP_OUTPUT_ROUTE; 321 bdIMADpj_getDeviceCapabilities(BD_IMAD_PLAYBACK_DEVICES,&wf->dev_info[captureDeviceCount+i].info.caps); 322 322 wf->dev_info[captureDeviceCount+i].info.default_samples_per_sec = 323 323 BD_IMAD_DEFAULT_FREQ; … … 707 707 strm->bdIMADpjSettingsPtr->FrameSize_ms = ptime; 708 708 strm->bdIMADpjSettingsPtr->DiagnosticEnable = BD_IMAD_DIAGNOSTIC; 709 strm->bdIMADpjSettingsPtr->DiagnosticFolderPath =710 709 mbstowcs(bdImadPjDiagnosticFolderPath, BD_IMAD_DIAGNOSTIC_PATH, strlen(BD_IMAD_DIAGNOSTIC_PATH)); 710 strm->bdIMADpjSettingsPtr->DiagnosticFolderPath = bdImadPjDiagnosticFolderPath; 711 711 strm->bdIMADpjSettingsPtr->validate = (void *)manage_code; 712 712 713 713 if(prm->clock_rate != 8000 && prm->clock_rate != 16000 714 && prm->clock_rate != 32000 && prm->clock_rate != 4 8000) {714 && prm->clock_rate != 32000 && prm->clock_rate != 44100 && prm->clock_rate != 48000) { 715 715 PJ_LOG(4, (THIS_FILE, 716 "BDIMAD support 8000 Hz, 16000 Hz, 32000 Hz and 48000 Hz "716 "BDIMAD support 8000 Hz, 16000 Hz, 32000 Hz, 44100 Hz and 48000 Hz " 717 717 "frequency.")); 718 718 } … … 767 767 BD_PARAM_IMAD_PJ_MIC_CONTROL_ENABLE, 768 768 &auxInt); 769 770 // Enable GUI Socket Communication [default->disabled] 771 bdIMADpj_enableGuiSocketCommunication(strm->bdIMADpjInstance,27000,0); 769 772 } 770 773 … … 934 937 if(cap == PJMEDIA_AUD_DEV_CAP_OUTPUT_ROUTE) { 935 938 pjmedia_aud_dev_route outputRoute = *(pjmedia_aud_dev_route*)pval; 936 if(strm->param.output_route!=outputRoute) 937 res = bdIMADpj_setRouteOutputDevice(strm->bdIMADpjInstance, (bdIMADpj_out_dev_route) outputRoute, &strm->bdIMADpjWarningPtr); 939 res = bdIMADpj_setRouteOutputDevice(strm->bdIMADpjInstance, (bdIMADpj_out_dev_route) outputRoute, &strm->bdIMADpjWarningPtr); 938 940 if(res == BD_PJ_OK) { 939 941 strm->param.output_route = outputRoute; … … 1220 1222 1221 1223 #if defined (_MSC_VER) 1222 #ifdef _DEBUG1223 #pragma comment ( lib, "bdClientValidationd.lib" )1224 #pragma comment ( lib, "bdIMADpjd.lib" )1225 #else1226 1224 #pragma comment ( lib, "bdClientValidation.lib" ) 1227 1225 #pragma comment ( lib, "bdIMADpj.lib" ) 1228 1226 #endif 1229 #endif1230 1227 1231 1228 -
pjproject/trunk/third_party/bdsound/include/bdimad.h
r4748 r5037 8 8 * @ingroup audio_device_api 9 9 * 10 * <b>bdSound IMproved Audio Device</b> is a multi platform audio interface10 * <b>bdSound IMproved Audio Device</b> is a multi-platform audio interface 11 11 * created to integrate in <b>PJSIP</b> library with no effort. 12 12 * \n Porting <b>bdIMADpj</b> across the main operating systems is … … 38 38 * - <b>Integration</b> 39 39 * \n Using <b>bdIMAD</b> within <b>PJSIP</b> is simple: 40 * -# Request for bdIMADpj library to 41 * <a href="http:/www.bdsound.com" target="new">bdSound</a>: 42 * bdSound will provide instruction to integrate the library depending on 43 * the platform / O.S. / toolchain; 44 * -# Add the <code>bdimad_dev.c</code> file to 45 * <code>pjmedia/src/pjmedia-audiodev</code> folder; 46 * -# Enable the bdIMAD audio device defining the periferal in the 47 * <code>pj/config_site.h</code> and disabling all other devices: 48 * <pre> 49 * #define PJMEDIA_AUDIO_DEV_HAS_BDIMAD 1 50 * </pre> 40 * -# Download trial bdIMADpj library from 41 * <a href="http:/www.bdsound.com" target="new">bdSound</a>; 42 * -# Follow the integration instructions at 43 * <a href="http:/www.bdsound.com/support" target="new">bdSound</a>: 51 44 * 52 45 * - <b>Usage</b> 53 46 * \n There are only a couple of things the customer have to pay attention on 54 * ï¿œwhen using bdIMAD library.47 * when using bdIMAD library. 55 48 * 56 49 * - <b>Initialization</b> 57 * \n Since the bdIMAD library provide itself the echo cancellation50 * \n Since the bdIMAD library provides itself the echo cancellation 58 51 * and the latency management, is necessary to disable these features 59 * in the PJSIP librar iy applications.52 * in the PJSIP library applications. 60 53 * \n For example in PJSUA sample application there is the need 61 54 * to provide the following commands: … … 71 64 * \n Setting speaker volume. 72 65 * - <code>PJMEDIA_AUD_DEV_CAP_INPUT_VOLUME_SETTING</code> 73 * \n Setting mic hrophone volume.66 * \n Setting microphone volume. 74 67 * - <code>PJMEDIA_AUD_DEV_CAP_EC</code> 75 68 * \n Enable/disable echo cancellation. 69 * - <code>PJMEDIA_AUD_DEV_CAP_OUTPUT_ROUTE</code> 70 * \n Support for audio output routing in mobile application(e.g. loudspeaker vs earpiece). 76 71 * 77 72 * For additional information visit … … 80 75 * 81 76 * @author bdSound 82 * @version 1.0.183 * @copyright 201 2bdSound srl. All rights reserved.77 * @version 2.0.0 rev.1618 78 * @copyright 2015 bdSound srl. All rights reserved. 84 79 * 85 80 */ … … 100 95 101 96 /** 102 * @defgroup groupStructEnum Structs and Enums 97 * @defgroup groupStructEnum Structs and Enums 103 98 * @ingroup bd_IMAD 104 99 * … … 140 135 * @brief Callback used to fill the playback buffer of bdIMAD. 141 136 * The function is called by bdIMAD each time are required sample to be played. 142 * @param[in] *buffer pointer to the buffer with the audio 143 * samples to be played(short type). 144 * @param[in] nSamples number of samples required. 145 * @param[in] user_data pointer to the user data structure 146 * defined in the bdIMADpj_Setting_t 147 * structure. 137 * 138 * @param[in] *buffer pointer to the buffer with the audio 139 * samples to be played (short type). 140 * 141 * @param[in] nSamples number of samples required. 142 * 143 * @param[in] user_data pointer to the user data structure 144 * defined in the bdIMADpj_Setting_t structure. 145 * 148 146 * @return none. 149 147 */ … … 153 151 154 152 /** 155 * @brief Callback used to retrive the caputre buffer of bdIMAD. The function 156 * is called by bdIMAD each time processed mic samples are available. 157 * @param[out] *buffer pointer to the buffer with the audio 158 * samples to download(short type). 159 * @param[in] nSamples number of samples processed to download. 160 * @param[in] user_data pointer to the user data structure 161 * defined in the MainSet structure. 153 * @brief Callback used to retrieve the capture buffer of bdIMAD. The function 154 * is called by bdIMAD each time processed microphone samples are available. 155 * 156 * @param[out] *buffer pointer to the buffer with the audio 157 * samples to be downloaded (short type). 158 * 159 * @param[in] nSamples number of samples processed to be downloaded. 160 * 161 * @param[in] user_data pointer to the user data structure 162 * defined in the bdIMADpj_Setting_t structure. 163 * 162 164 * @return none. 163 165 */ … … 178 180 */ 179 181 180 typedef enum bdIMADpj_Status {181 /** <No error. */182 typedef enum bdIMADpj_Status { 183 /** No error. */ 182 184 BD_PJ_OK = 0, 183 /** < Watch bdIMADpj_Warnings_t structure to find the warnings. */185 /** The warnings can be find in the bdIMADpj_Warnings_t structure . */ 184 186 BD_PJ_WARN_BDIMAD_WARNING_ASSERTED = 1, 185 /** <Error not identified. */187 /** Error not identified. */ 186 188 BD_PJ_ERROR_GENERIC = 2, 187 /** <The pointer passed is NULL. */189 /** The pointer passed is NULL. */ 188 190 BD_PJ_ERROR_NULL_POINTER = 3, 189 /** <Allocation procedure failed. */191 /** Allocation procedure failed. */ 190 192 BD_PJ_ERROR_ALLOCATION = 4, 191 /** <The parameter is not existent or the set/get function is not active. */193 /** The parameter is not existent or the set/get function is not active. */ 192 194 BD_PJ_ERROR_PARAMETER_NOT_FOUND = 5, 193 /** <No capture device found. */195 /** No capture device found. */ 194 196 BD_PJ_ERROR_IMAD_NONE_CAPTURE_DEV = 10, 195 /** <No play device found. */197 /** No play device found. */ 196 198 BD_PJ_ERROR_IMAD_NONE_PLAY_DEV = 11, 197 /** <Frame size not allowed. */199 /** Frame size not allowed. */ 198 200 BD_PJ_ERROR_IMAD_FRAME_SIZE = 12, 199 /** <Sample frequency not allowed. */201 /** Sample frequency not allowed. */ 200 202 BD_PJ_ERROR_IMAD_SAMPLE_FREQ = 13, 201 /** <Samples missing. */203 /** Samples missing. */ 202 204 BD_PJ_ERROR_IMAD_MISSING_SAMPLES = 14, 203 /** <Device list is empty. */205 /** Device list is empty. */ 204 206 BD_PJ_ERROR_IMAD_DEVICE_LIST_EMPTY = 15, 205 /** <Library not authorized, entering demo mode. */207 /** Library not authorized, entering demo mode. */ 206 208 BD_PJ_ERROR_IMAD_LIB_NOT_AUTHORIZED = 16, 207 /** <The input channel memory has not been allocated. */209 /** The input channel memory has not been allocated. */ 208 210 BD_PJ_ERROR_IMAD_INPUT_CH_NOT_ALLOCATED = 17, 209 /** <The library has expired, entering demo mode. */211 /** The library has expired, entering demo mode. */ 210 212 BD_PJ_ERROR_IMAD_LICENSE_EXPIRED = 18, 211 /** <Open of capture device failed. */213 /** Open of capture device failed. */ 212 214 BD_PJ_ERROR_IMAD_OPEN_CAPTURE_DEV_FAILED = 19, 213 /** <Open of play device failed. */215 /** Open of play device failed. */ 214 216 BD_PJ_ERROR_IMAD_OPEN_PLAY_DEV_FAILED = 20, 215 /** <Start of play device failed. */217 /** Start of play device failed. */ 216 218 BD_PJ_ERROR_IMAD_START_PLAY_DEV_FAILED = 21, 217 /** <Start of capture device failed. */219 /** Start of capture device failed. */ 218 220 BD_PJ_ERROR_IMAD_START_CAPTURE_DEV_FAILED = 22, 219 /** <Start of time process failed. */221 /** Start of time process failed. */ 220 222 BD_PJ_ERROR_IMAD_START_TIME_PROCESS_FAILED = 23, 221 /** <Start of thread process failed. */223 /** Start of thread process failed. */ 222 224 BD_PJ_ERROR_IMAD_THREAD_PROCESS_FAILED = 24, 223 /** <No volume control available. */225 /** No volume control available. */ 224 226 BD_PJ_ERROR_IMAD_NO_VOL_CONTROL_AVAILABLE = 25, 225 227 } bdIMADpj_Status; … … 232 234 */ 233 235 234 typedef enum bdIMADpj_Parameter{ 235 /**< int* \n set/get \n 1 enable / 0 disable echo cancellation. */ 236 BD_PARAM_IMAD_PJ_AEC_ENABLE = 1, 237 /**< int* \n set/get \n 1 enable / 0 disable microphone control 236 typedef enum bdIMADpj_Parameter { 237 /** int* \n set/get \n 1 enable / 0 disable echo cancellation. */ 238 BD_PARAM_IMAD_PJ_AEC_ENABLE = 0, 239 /** int* \n set/get \n 0 -> 256 ms of echo tail. */ 240 BD_PARAM_IMAD_PJ_AEC_ECHO_TAIL_MS = 1, 241 /** int* \n set/get \n 0 -> 400 ms of delay offset. */ 242 BD_PARAM_IMAD_PJ_AEC_DELAY_OFFSET_MS = 2, 243 /** int* \n set/get \n 1 enable / 0 disable automatic delay estimation. */ 244 BD_PARAM_IMAD_PJ_AEC_AUTO_DELAY_ESTIMATION_ENABLE = 3, 245 /** int* \n get \n estimated delay in ms. */ 246 BD_PARAM_IMAD_PJ_AEC_AUTO_DELAY_ESTIMATION_VALUE = 4, 247 /** int* \n get \n 1 is stable / 0 not yet stable estimated delay. */ 248 BD_PARAM_IMAD_PJ_AEC_AUTO_DELAY_ESTIMATION_IS_STABLE = 5, 249 /** int* \n set/get \n 1 enable / 0 disable Noise Reduction. */ 250 BD_PARAM_IMAD_PJ_NR_ENABLE = 6, 251 /** int* \n set/get \n 0 low / 1 medium / 2 high / 3 very high / 4 adaptive level of Noise Reduction. */ 252 BD_PARAM_IMAD_PJ_NR_LEVEL = 7, 253 /** int* \n set/get \n 1 enable / 0 disable Comfort Noise Generator. */ 254 BD_PARAM_IMAD_PJ_CNG_ENABLE = 8, 255 /** int* \n set/get \n 1 adaptive / 0 not adaptive mode of Comfort Noise Generator. */ 256 BD_PARAM_IMAD_PJ_CNG_SET_ADAPTIVE = 9, 257 /** int* \n set/get \n -40 -> -100 dBFS fixed power level of Comfort Noise Generator, when adaptive mode is disabled. */ 258 BD_PARAM_IMAD_PJ_CNG_FIXED_LEVEL_DB = 10, 259 /** int* \n set/get \n 0 minimal / 1 low / 2 intermediate / 3 high / 4 aggressive effort level of Residual Echo Canceller. */ 260 BD_PARAM_IMAD_PJ_REC_EFFORT_LEVEL = 11, 261 /** int* \n set/get \n 1 enable / 0 disable Non Linear Processor. */ 262 BD_PARAM_IMAD_PJ_NLP_ENABLE = 12, 263 /** float* \n set/get \n 6.0f -> 24.0f dB Double Talk Detector sensitivity. */ 264 BD_PARAM_IMAD_PJ_NLP_DTD_SENSITIVITY = 13, 265 /** float* \n set/get \n -50.0f -> 0.0f dB maximum applicable gain by the Non Linear Processor. */ 266 BD_PARAM_IMAD_PJ_NLP_GAIN = 14, 267 /** int* \n set/get \n 1 enable / 0 disable microphone control 238 268 * (when possible). */ 239 BD_PARAM_IMAD_PJ_MIC_CONTROL_ENABLE = 2, 240 /**< int* \n set/get \n 1 ebable / 0 disable noise reduction. */ 241 BD_PARAM_IMAD_PJ_NOISE_REDUCTION_ENABLE = 3, 242 /**< int* \n set \n number of channel to reset. Used to reset 243 * the input channel statistics. To be used when the same channel 244 * is assigned to another partecipant. */ 245 BD_PARAM_IMAD_PJ_RESET_STATISTIC_IN_CH = 4, 246 /**< float* \n set/get \n 0.0f -> 1.0f volume of 269 BD_PARAM_IMAD_PJ_MIC_CONTROL_ENABLE = 15, 270 /** float* \n set/get \n 0.0f -> 1.0f volume of 247 271 * the microphone(when possible). */ 248 BD_PARAM_IMAD_PJ_MIC_VOLUME = 5,249 /** <int* \n set/get \n 0 mute / 1 not mute on microphone272 BD_PARAM_IMAD_PJ_MIC_VOLUME = 16, 273 /** int* \n set/get \n 0 mute / 1 not mute on microphone 250 274 * (when possible). */ 251 BD_PARAM_IMAD_PJ_MIC_MUTE = 6,252 /** <float* \n set/get \n 0.0f -> 1.0f volume of the speaker. */253 BD_PARAM_IMAD_PJ_SPK_VOLUME = 7,254 /** <int* \n set/get \n 0 mute / 1 not mute on speaker. */255 BD_PARAM_IMAD_PJ_SPK_MUTE = 8,275 BD_PARAM_IMAD_PJ_MIC_MUTE = 17, 276 /** float* \n set/get \n 0.0f -> 1.0f volume of the speaker. */ 277 BD_PARAM_IMAD_PJ_SPK_VOLUME = 18, 278 /** int* \n set/get \n 0 mute / 1 not mute on speaker. */ 279 BD_PARAM_IMAD_PJ_SPK_MUTE = 19, 256 280 } bdIMADpj_Parameter; 257 281 258 259 /** 260 * @brief Instance structure for the information regarding the aec engine. 261 */ 262 263 typedef struct bdIMADpj_Setting_t{ 264 /**< Sample frequency (8kHz or 16kHz). */ 282 /** 283 * @brief Direction path of the parameter to be used in set and get audio process parameter functions. 284 * 285 */ 286 typedef enum bdIMADpj_DirPath { 287 /** Indicates the send direction path (microphone). */ 288 BD_IMAD_PJ_DIR_PATH_SEND = 0, 289 /** Indicates the receive direction path (speaker). */ 290 BD_IMAD_PJ_DIR_PATH_RECV = 1, 291 } bdIMADpj_DirPath; 292 293 /** 294 * @brief Audio processing parameter to pass to set and get audio processing parameter functions. 295 * 296 * For each enumeration are defined the data type and the supported operations 297 * on that parameter (set and get). 298 */ 299 300 typedef enum bdIMADpj_AudioProcessParameter { 301 /** int* \n set/get \n 1 enable / 0 disable whole audio processing chain. */ 302 BD_AP_PARAM_IMAD_PJ_AUDIO_PROC_ENABLE = 200, 303 /** int* \n set/get \n 1 enable / 0 disable digital gain. */ 304 BD_AP_PARAM_IMAD_PJ_GAIN_ENABLE = 201, 305 /** float* \n set/get \n 0.0f -> 20.0f dB digital gain value. */ 306 BD_AP_PARAM_IMAD_PJ_GAIN_VALUE_DB = 202, 307 /** int* \n set/get \n 1 enable / 0 disable Automatic Gain Control. */ 308 BD_AP_PARAM_IMAD_PJ_AGC_ENABLE = 203, 309 /** float* \n set/get \n 0.0f -> -30.0f dBFS target RMS power of the Automatic Gain Control. */ 310 BD_AP_PARAM_IMAD_PJ_AGC_TARGET_RMS_DB = 204, 311 /** float* \n set/get \n 0.0f -> 15.0f dB maximum applicable gain by the Automatic Gain Control. */ 312 BD_AP_PARAM_IMAD_PJ_AGC_MAX_GAIN_DB = 205, 313 /** int* \n set/get \n 1 enable / 0 disable Graphic Equalizer (10 bands). */ 314 BD_AP_PARAM_IMAD_PJ_GEQ_ENABLE = 206, 315 /** float* \n set/get \n Graphic Equalizer (10 bands) frequencies and gains. \n 316 Float array of 30 elements, composed by 10 triplets (enable, frequency, gain_dB). \n 317 First field, enable: 1.0f enable / 0.0f disable the frequency filter. \n 318 Second field, frequency: 0.0f -> Fs/2 Hz centre frequency of the filter. \n 319 Third field, gain_dB: -18.0f -> 18.0f dB gain of the filter. 320 Frequency values in ascending order. \n */ 321 BD_AP_PARAM_IMAD_PJ_GEQ_FREQ_GAIN = 207, 322 /** int* \n set/get \n 1 enable / 0 disable Compander. */ 323 BD_AP_PARAM_IMAD_PJ_CMP_ENABLE = 208, 324 /** float* \n set/get \n 0.0f -> 5000.0f ms attack time of gain processor of the Compander. */ 325 BD_AP_PARAM_IMAD_PJ_CMP_ATTACK_TIME_GAIN_MS = 209, 326 /** float* \n set/get \n 0.0f -> 5000.0f ms release time of gain processor of the Compander. */ 327 BD_AP_PARAM_IMAD_PJ_CMP_RELEASE_TIME_GAIN_MS = 210, 328 /** float* \n set/get \n 0.0f -> 5000.0f ms attack time of level measurement of the Compander. */ 329 BD_AP_PARAM_IMAD_PJ_CMP_ATTACK_TIME_LEVEL_MS = 211, 330 /** float* \n set/get \n 0.0f -> 5000.0f ms release time of level measurement of the Compander. */ 331 BD_AP_PARAM_IMAD_PJ_CMP_RELEASE_TIME_LEVEL_MS = 212, 332 /** int* \n set/get \n 0 -> 10 ms lookahead time of the Compander. */ 333 BD_AP_PARAM_IMAD_PJ_CMP_LOOK_AHEAD_MS = 213, 334 /** int* \n set/get \n 1 RMS / 0 peak detector of the Compander selected. */ 335 BD_AP_PARAM_IMAD_PJ_CMP_RMS_DETECTOR = 214, 336 /** float* \n set/get \n 0.0f -> 12.0f dB compensation gain of the Compander. */ 337 BD_AP_PARAM_IMAD_PJ_CMP_COMPENSATION_GAIN_DB = 215, 338 /** float* \n set/get \n Float sorted array of static gain curve points in dB - up to 4 points: input0, output0, ⊠, input3, output3. 339 Gain values: 0.0f -> -100.0f dB. */ 340 BD_AP_PARAM_IMAD_PJ_CMP_TABLE = 216, 341 /** int* \n set/get \n 1 enable / 0 disable Limiter. */ 342 BD_AP_PARAM_IMAD_PJ_LIM_ENABLE = 217, 343 /** float* \n set/get \n 0.0f -> -40.0f dBFS threshold value of the Limiter. */ 344 BD_AP_PARAM_IMAD_PJ_LIM_THRESHOLD = 218, 345 } bdIMADpj_AudioProcessParameter; 346 347 348 /** 349 * @brief Test signal type to be used in set and get test parameter functions. 350 * 351 */ 352 typedef enum bdIMADpj_TestSignalType { 353 /** Indicates a sine wave. */ 354 BD_IMAD_PJ_TS_SINE = 0, 355 /** Indicates a White Gaussian Noise. */ 356 BD_IMAD_PJ_TS_WGN = 1, 357 } bdIMADpj_TestSignalType; 358 359 360 /** 361 * @brief Test parameter to pass to set and get test parameter functions. 362 * 363 * For each enumeration are defined the data type and the supported operations 364 * on that parameter (set and get). 365 */ 366 typedef enum bdIMADpj_TestParameter { 367 /** int* \n set/get \n 1 enable / 0 disable Test Signal. */ 368 BD_TEST_PARAM_IMAD_PJ_TEST_SIGNAL_ENABLE = 400, 369 /** bdIMADpj_TestSignalType* \n set/get \n Test Signal type: sine or Wgn. */ 370 BD_TEST_PARAM_IMAD_PJ_TEST_SIGNAL_TYPE = 401, 371 /** int* \n set/get \n 0 -> -100 dBFS amplitude of Test Signal. */ 372 BD_TEST_PARAM_IMAD_PJ_TEST_SIGNAL_AMPLITUDE = 402, 373 /** float* \n set/get \n 0 -> Fs/2 Hz frequency of sine Test Signal . */ 374 BD_TEST_PARAM_IMAD_PJ_TEST_SIGNAL_FREQUENCY = 403, 375 } bdIMADpj_TestParameter; 376 377 /** 378 * @brief Side to be used in get VU meter level value function. 379 * 380 */ 381 typedef enum bdIMADpj_Side { 382 /** Indicates the input side of a direction path. */ 383 BD_IMAD_PJ_SIDE_INPUT = 0, 384 /** Indicates the output side of a direction path. */ 385 BD_IMAD_PJ_SIDE_OUTPUT = 1, 386 } bdIMADpj_Side; 387 388 389 /** 390 * @brief Instance structure for the information regarding the AEC engine. 391 */ 392 393 typedef struct bdIMADpj_Setting_t { 394 /** Sample frequency (8kHz - 16kHz - 32kHz - 44.1kHz - 48kHz). */ 265 395 int SamplingFrequency; 266 /** < Audio buffer managed by the aecbdIMAD functions.396 /** Audio buffer managed by the AEC bdIMAD functions. 267 397 * (from 16ms to 80ms, 16ms recommended). */ 268 398 int FrameSize_ms; 269 /** < Pointsto the validation functions in the validation library. */399 /** Pointer to the validation functions in the validation library. */ 270 400 void *validate; 271 /** < Pointsto the the callback function used for filling401 /** Pointer to the the callback function used for filling 272 402 * the playback buffer of bdIMAD. */ 273 403 cb_fillPlayBackB_t cb_fillPlayBackBuffer; 274 /** < Points to user data to pass to the callback. */404 /** Pointer to user data to pass to the callback (playback). */ 275 405 void *cb_fillPlayBackBuffer_user_data; 276 /** < Points to the callback function used for retreive the processed406 /** Pointer to the callback function used for retrieve the processed 277 407 * audio present in the capture buffer of bdIMAD. */ 278 408 cb_emptyCaptureB_t cb_emptyCaptureBuffer; 279 /** < Points to user data to pass to the callback. */409 /** Pointer to user data to pass to the callback (capture). */ 280 410 void *cb_emptyCaptureBuffer_user_data; 281 /** <Is a wide char pointer to the capture device name. */411 /** Is a wide char pointer to the capture device name. */ 282 412 wchar_t *CaptureDevice; 283 /** <Is a wide char pointer to the play device name. */413 /** Is a wide char pointer to the play device name. */ 284 414 wchar_t *PlayDevice; 285 /** <True to enable diagnostic, false to disable. */415 /** True to enable diagnostic, false to disable. */ 286 416 int DiagnosticEnable; 287 /** <Directory which will contains the files generated for diagnostic. */417 /** Directory which will contains the files generated for diagnostic. */ 288 418 wchar_t *DiagnosticFolderPath; 289 /** <Is an auxiliary settings pointer used internally by bdIMAD. */419 /** Is an auxiliary settings pointer used internally by bdIMAD. */ 290 420 void *bdIMADwr_SettingsData; 291 421 } bdIMADpj_Setting_t; … … 296 426 */ 297 427 298 typedef struct bdIMADpj_Warnings_t {299 /** < The capture device indicated can't be opened, has been selected300 * the default capture device. */428 typedef struct bdIMADpj_Warnings_t { 429 /** The capture device indicated can't be opened, then the default capture device 430 * has been selected. */ 301 431 int DefaultCaptureDeviceAutomaticallySelected; 302 /** <The capture device opened has not volume control. */432 /** The capture device opened has not volume control. */ 303 433 int CaptureDeviceWithoutVolumeControl; 304 /** < The play device indicated can't be opened, has been selected305 * the default play device. */434 /** The play device indicated can't be opened, then the default play device 435 * has been selected. */ 306 436 int DefaultPlayDeviceAutomaticallySelected; 307 /** < The number of channelrequested is out of range. The number of308 * channelopened is equal to the maximum. */437 /** The number of channels requested is out of range. The number of 438 * channels opened is equal to the maximum. */ 309 439 int NumberOfChannelsOutOfRange; 310 /** <The diagnostic files could not be saved. */440 /** The diagnostic files could not be saved. */ 311 441 int DiagnosticSaveNotAllowed; 312 /** <The nlp level requested is not allowed, it has been automatically313 * changed to the default value. */442 /** The nlp level requested is not allowed, it has been automatically 443 * changed to the default value. */ 314 444 int nlpLevelChangeSettting; 315 /** < No capture device is present. Anyway the bdSES has been316 * istantiatedonly for playback. */445 /** No capture device is present. Anyway the bdSES has been instantiated 446 * only for playback. */ 317 447 int NoCaptureDevicePresent; 318 /** < The cpu is not adapt to run the aec engine, the aechas been disabled.319 * This appens for very old cpulike pentium III. */448 /** The CPU is not adapt to run the AEC engine, the AEC has been disabled. 449 * This happens for very old CPU like pentium III. */ 320 450 int oldCPUdetected_AECdisable; 321 /** <Windows Direct Sound error. */451 /** Windows Direct Sound error. */ 322 452 long directSoundError; 323 /** <Windows Direct Sound volume error. */453 /** Windows Direct Sound volume error. */ 324 454 long directSoundLevel; 325 /** < No play device is present. Anyway the bdSES has been istantiated326 * only for capture. */455 /** No play device is present. Anyway the bdSES has been instantiated 456 * only for capture. */ 327 457 int NoPlayDevicePresent; 328 458 } bdIMADpj_Warnings_t; … … 332 462 */ 333 463 334 typedef struct bdIMADpj_libVersion_t {464 typedef struct bdIMADpj_libVersion_t { 335 465 int major; /**< major version. */ 336 466 int minor; /**< minor version. */ … … 345 475 * @brief Audio output routing setting to pass to set and get route output device functions. 346 476 */ 347 typedef enum bdIMADpj_out_dev_route {348 /** Default route .*/349 BD_AUD_DEV_ROUTE_DEFAULT 477 typedef enum bdIMADpj_out_dev_route { 478 /** Default route */ 479 BD_AUD_DEV_ROUTE_DEFAULT = 0, 350 480 351 481 /** Route to loudspeaker */ 352 BD_AUD_DEV_ROUTE_LOUDSPEAKER 482 BD_AUD_DEV_ROUTE_LOUDSPEAKER = 1, 353 483 354 484 /** Route to earpiece */ 355 BD_AUD_DEV_ROUTE_EARPIECE 485 BD_AUD_DEV_ROUTE_EARPIECE = 2 356 486 }bdIMADpj_out_dev_route; 357 487 … … 376 506 * for the bdIMAD. 377 507 * 378 * The function generate a structure bdIMADpj_Setting_t filled with the508 * The function generates a structure bdIMADpj_Setting_t filled with the 379 509 * default settings. 380 510 * \n The user can change this settings according to the need and then 381 511 * launch the ::bdIMADpj_InitAEC. 382 * \n The function generate also a warning structure (::bdIMADpj_Warnings_t)512 * \n The function generates also a warning structure (::bdIMADpj_Warnings_t) 383 513 * that could be used in ::bdIMADpj_InitAEC to handle eventual warnings. 384 * @param[out] **ppSettings Points to the pointer of the 385 * allocated ::bdIMADpj_Setting_t. 386 * @param[out] **ppWarningMessages Points to the pointer of the 387 * allocated ::bdIMADpj_Warnings_t. 388 * @return ::BD_PJ_OK if the function has been 389 * performed successfully, otherwise return 390 * an error (refer to ::bdIMADpj_Status). 514 * 515 * @param[out] **ppSettings Pointer to the pointer of the 516 * allocated ::bdIMADpj_Setting_t. 517 * 518 * @param[out] **ppWarningMessages Pointer to the pointer of the 519 * allocated ::bdIMADpj_Warnings_t. 520 * 521 * @return ::BD_PJ_OK if the function has been 522 * performed successfully, otherwise return 523 * an error (refer to ::bdIMADpj_Status). 391 524 */ 392 525 BDIMADPJ_API bdIMADpj_Status bdIMADpj_CreateStructures( … … 398 531 * ::bdIMADpj_Warnings_t structure allocated with 399 532 * the ::bdIMADpj_CreateStructures. 400 * @param[in] **ppSettings Pointer to a memory location filled 401 * with the address of the 402 * ::bdIMADpj_Setting_t structure to free. 403 * This address will be set to NULL. 404 * @param[in] **ppWarningMessages Pointer to a memory location filled 405 * with the address of the allocated 406 * ::bdIMADpj_Warnings_t structure to free. 407 * This address will be set to NULL. 408 * @return ::BD_PJ_OK if the function has been 409 * performed successfully, otherwise return 410 * an error (refer to ::bdIMADpj_Status). 533 * @param[in] **ppSettings Pointer to a memory location filled 534 * with the address of the 535 * ::bdIMADpj_Setting_t structure to free. 536 * This address will be set to NULL. 537 * 538 * @param[in] **ppWarningMessages Pointer to a memory location filled 539 * with the address of the allocated 540 * ::bdIMADpj_Warnings_t structure to free. 541 * This address will be set to NULL. 542 * 543 * @return ::BD_PJ_OK if the function has been 544 * performed successfully, otherwise return 545 * an error (refer to ::bdIMADpj_Status). 411 546 */ 412 547 BDIMADPJ_API bdIMADpj_Status bdIMADpj_FreeStructures( … … 417 552 * @brief Is used to initialize the memory for bdIMAD with the settings 418 553 * contained in the <code>ppSettings</code>. 419 * @param[out] *pBdIMADInstance Is the pointer to the bdIMAD object. 420 * @param[in] **ppSettings Pointer to pointer to a 421 * ::bdIMADpj_Setting_t structure, filled 422 * with initialization settings to be 423 * applied to the bdIMAD. 424 * \n Note, the <code>pBdIMADInstance</code> 425 * is modified with the applied settings. 426 * @param[out] **ppWarningMessages Pointer to pointer to a 427 * ::bdIMADpj_Warnings_t structure, 428 * which reports the warnings after the 429 * initialization. 430 * @return ::BD_PJ_OK if the function has been 431 * performed successfully, otherwise return 432 * an error (refer to ::bdIMADpj_Status). 433 * \n If the error is 434 * ::BD_PJ_WARN_BDIMAD_WARNING_ASSERTED 435 * the init has been performed with success, 436 * but with a different settings 437 * respect to the ones required. 438 * This mainly happens if the audio 439 * device opened is different to the 440 * one requested. 554 * 555 * @param[out] *pBdIMADInstance Is the pointer to the bdIMAD object. 556 * 557 * @param[in] **ppSettings Pointer to pointer to a 558 * ::bdIMADpj_Setting_t structure, filled 559 * with initialization settings to be 560 * applied to the bdIMAD. 561 * \n Note, the <code>pBdIMADInstance</code> 562 * is modified with the applied settings. 563 * 564 * @param[out] **ppWarningMessages Pointer to pointer to a 565 * ::bdIMADpj_Warnings_t structure, 566 * which reports the warnings after the 567 * initialization. 568 * 569 * @return ::BD_PJ_OK if the function has been 570 * performed successfully, otherwise return 571 * an error (refer to ::bdIMADpj_Status). 572 * \n If the error is 573 * ::BD_PJ_WARN_BDIMAD_WARNING_ASSERTED 574 * the init function has been performed with success, 575 * but with a different settings 576 * respect to the ones required. 577 * This mainly happens if the audio 578 * device opened is different to the 579 * one requested. 441 580 */ 442 581 BDIMADPJ_API bdIMADpj_Status bdIMADpj_InitAEC(bdIMADpj *pBdIMADInstance, … … 447 586 * @brief Is used to free the bdIMAD object pointed by the 448 587 * <code>pBdIMADInstance</code>. 449 * @param[in] *pBdIMADInstance Pointer to the bdIMAD object to free. 450 * @return ::BD_PJ_OK if the function has been 451 * performed successfully, otherwise return 452 * an error (refer to ::bdIMADpj_Status). 588 * 589 * @param[in] *pBdIMADInstance Pointer to the bdIMAD object to free. 590 * 591 * @return ::BD_PJ_OK if the function has been 592 * performed successfully, otherwise return 593 * an error (refer to ::bdIMADpj_Status). 453 594 */ 454 595 BDIMADPJ_API bdIMADpj_Status bdIMADpj_FreeAEC(bdIMADpj *pBdIMADInstance); 455 596 456 597 /** 457 * @brief Is used to make a list of cap ure and play devices available598 * @brief Is used to make a list of capture and play devices available 458 599 * on the system. 459 * @param[in] captureDevice Set to 1 to get the list of capture 460 * devices. Set to 0 to get the list of 461 * play devices. 462 * @param[in] **deviceName Pointer to pointer to a wide char 463 * containing the names of capture/play 464 * devices. 465 * @return ::BD_PJ_OK if the function has been 466 * performed successfully, otherwise return 467 * an error (refer to ::bdIMADpj_Status). 600 * 601 * @param[in] captureDevice Set to 1 to get the list of capture 602 * devices. Set to 0 to get the list of 603 * play devices. 604 * 605 * @param[in] **deviceName Pointer to pointer to a wide char 606 * containing the names of capture/play 607 * devices. 608 * 609 * @return ::BD_PJ_OK if the function has been 610 * performed successfully, otherwise return 611 * an error (refer to ::bdIMADpj_Status). 468 612 */ 469 613 BDIMADPJ_API bdIMADpj_Status bdIMADpj_getDeviceName(int captureDevice, … … 473 617 * @brief Is used to freeze the bdIMAD, stopping the audio playback 474 618 * and recording. 475 * @param[in] bdIMADInstance bdIMAD object. 476 * @return ::BD_PJ_OK if the function has been 477 * performed successfully, otherwise 478 * return an error (refer to 479 * ::bdIMADpj_Status). 619 * 620 * @param[in] bdIMADInstance bdIMAD object. 621 * 622 * @return ::BD_PJ_OK if the function has been 623 * performed successfully, otherwise return 624 * an error (refer to ::bdIMADpj_Status). 480 625 */ 481 626 BDIMADPJ_API bdIMADpj_Status bdIMADpj_stop(bdIMADpj bdIMADInstance); … … 494 639 /** 495 640 * @brief Print on a standard output the warning messages. 496 * @param[in] *pWarningMessages Pointer to the warning structure 497 * to be printed. 498 * @return ::BD_PJ_OK if the function has been 499 * performed successfully, otherwise 500 * return an error 501 * (refer to ::bdIMADpj_Status). 641 * 642 * @param[in] *pWarningMessages Pointer to the warning structure 643 * to be printed. 644 * 645 * @return ::BD_PJ_OK if the function has been 646 * performed successfully, otherwise return 647 * an error (refer to ::bdIMADpj_Status). 502 648 */ 503 649 BDIMADPJ_API bdIMADpj_Status bdIMADpj_DisplayWarnings( … … 506 652 /** 507 653 * @brief Clear the warning structure after being read. 508 * @param[out] **ppWarningMessages Pointer to pointer to the warning 509 * structure to be cleared. 510 * @return ::BD_PJ_OK if the function has been 511 * performed successfully, otherwise 512 * return an error (refer to 513 * ::bdIMADpj_Status). 654 * 655 * @param[out] **ppWarningMessages Pointer to pointer to the warning 656 * structure to be cleared. 657 * 658 * @return ::BD_PJ_OK if the function has been 659 * performed successfully, otherwise return 660 * an error (refer to ::bdIMADpj_Status). 514 661 */ 515 662 BDIMADPJ_API bdIMADpj_Status bdIMADpj_ClearAllWarnings( … … 519 666 * @brief Is used to set a parameter of the bdIMAD object pointed by the 520 667 * <code>pBdIMADInstance</code>. 521 * @param[in] bdIMADInstance bdIMAD object. 522 * @param[in] parameterName Indicate the parameter to set. 523 * @param[in] *pValue Is a pointer to the value to set 524 * cast to void. 525 * \n In the ::bdIMADpj_Parameter 526 * declaration is indicated the real type of 527 * the value, depending on the 528 * <code>parameterName</code>. 529 * @return ::BD_PJ_OK if the function has been 530 * performed successfully, otherwise 531 * return an error (refer to 532 * ï¿œ::bdIMADpj_Status). 668 * 669 * @param[in] bdIMADInstance bdIMAD object. 670 * 671 * @param[in] parameterName Indicates the parameter to be set. 672 * 673 * @param[in] *pValue Is a pointer to the value to be set. 674 * \n In the ::bdIMADpj_Parameter 675 * declaration is indicated the type of 676 * the value, depending on the 677 * <code>parameterName</code>. 678 * 679 * @return ::BD_PJ_OK if the function has been 680 * performed successfully, otherwise return 681 * an error (refer to ::bdIMADpj_Status). 533 682 */ 534 683 BDIMADPJ_API bdIMADpj_Status bdIMADpj_setParameter(bdIMADpj bdIMADInstance, … … 538 687 * @brief Is used to get a parameter of the bdIMAD object pointed by the 539 688 * <code>pBdIMADInstance</code>. 540 * @param[in] bdIMADInstance bdIMAD object. 541 * @param[in] parameterName Indicate the parameter to get. 542 * @param[out] *pValue Is a pointer to the value to get cast 543 * to void. \n In the 544 * ::bdIMADpj_Parameter declaration is 545 * indicated the real type of the value, 546 * depending on the 547 * <code>parameterName</code>. 548 * @return ::BD_PJ_OK if the function has been 549 * performed successfully, otherwise return 550 * an error (refer to ::bdIMADpj_Status). 689 * 690 * @param[in] bdIMADInstance bdIMAD object. 691 * 692 * @param[in] parameterName Indicates the parameter to be get. 693 * 694 * @param[out] *pValue Is a pointer to the value to be get. 695 * \n In the ::bdIMADpj_Parameter 696 * declaration is indicated the type of 697 * the value, depending on the 698 * <code>parameterName</code>. 699 * 700 * @return ::BD_PJ_OK if the function has been 701 * performed successfully, otherwise return 702 * an error (refer to ::bdIMADpj_Status). 551 703 */ 552 704 BDIMADPJ_API bdIMADpj_Status bdIMADpj_getParameter(bdIMADpj bdIMADInstance, 553 705 bdIMADpj_Parameter parameterName, void *pValue); 554 706 707 708 /** 709 * @brief Is used to set an audio processing parameter of the bdIMAD object pointed by the 710 * <code>pBdIMADInstance</code>. 711 * 712 * @param[in] bdIMADInstance bdIMAD object. 713 * 714 * @param[in] parameterName Indicates the parameter to be set. 715 * 716 * @param[in] directionPath Indicates the send/receive direction path. 717 * The parameter will be set to the audio process block 718 * located in the selected path. 719 * 720 * @param[in] *pValue Is a pointer to the value to be set. 721 * \n In the ::bdIMADpj_AudioProcessParameter 722 * declaration is indicated the real type of 723 * the value, depending on the 724 * <code>parameterName</code>. 725 * 726 * @return ::BD_PJ_OK if the function has been 727 * performed successfully, otherwise return 728 * an error (refer to ::bdIMADpj_Status). 729 */ 730 BDIMADPJ_API bdIMADpj_Status bdIMADpj_setAudioProcessParameter(bdIMADpj bdIMADInstance, 731 bdIMADpj_AudioProcessParameter parameterName, bdIMADpj_DirPath directionPath, void *pValue); 732 733 /** 734 * @brief Is used to get an audio processing parameter of the bdIMAD object pointed by the 735 * <code>pBdIMADInstance</code>. 736 * 737 * @param[in] bdIMADInstance bdIMAD object. 738 * 739 * @param[in] parameterName Indicates the parameter to be get. 740 * 741 * @param[in] directionPath Indicates the send/receive direction path. 742 * The parameter will be get from the audio process block 743 * located in the selected path. 744 * 745 * @param[out] *pValue Is a pointer to the value to be get. 746 * \n In the ::bdIMADpj_AudioProcessParameter 747 * declaration is indicated the real type of 748 * the value, depending on the 749 * <code>parameterName</code>. 750 * 751 * @return ::BD_PJ_OK if the function has been 752 * performed successfully, otherwise return 753 * an error (refer to ::bdIMADpj_Status). 754 */ 755 BDIMADPJ_API bdIMADpj_Status bdIMADpj_getAudioProcessParameter(bdIMADpj bdIMADInstance, 756 bdIMADpj_AudioProcessParameter parameterName, bdIMADpj_DirPath directionPath, void *pValue); 757 758 /** 759 * @brief Is used to set a test parameter of the bdIMAD object pointed by the 760 * <code>pBdIMADInstance</code>. 761 * 762 * @param[in] bdIMADInstance bdIMAD object. 763 * 764 * @param[in] parameterName Indicates the parameter to be set. 765 * 766 * @param[in] directionPath Indicates the send/receive direction path. 767 * The parameter will be set to the test generator block 768 * located in the selected path. 769 * 770 * @param[in] *pValue Is a pointer to the value to be set. 771 * \n In the ::bdIMADpj_TestParameter 772 * declaration is indicated the real type of 773 * the value, depending on the 774 * <code>parameterName</code>. 775 * 776 * @return ::BD_PJ_OK if the function has been 777 * performed successfully, otherwise return 778 * an error (refer to ::bdIMADpj_Status). 779 */ 780 BDIMADPJ_API bdIMADpj_Status bdIMADpj_setTestParameter(bdIMADpj bdIMADInstance, bdIMADpj_TestParameter parameterName, bdIMADpj_DirPath directionPath, void* pValue); 781 782 /** 783 * @brief Is used to get a test parameter of the bdIMAD object pointed by the 784 * <code>pBdIMADInstance</code>. 785 * 786 * @param[in] bdIMADInstance bdIMAD object. 787 * 788 * @param[in] parameterName Indicates the parameter to be get. 789 * 790 * @param[in] directionPath Indicates the send/receive direction path. 791 * The parameter will be get from the test generator block 792 * located in the selected path. 793 * 794 * @param[out] *pValue Is a pointer to the value to be get. 795 * \n In the ::bdIMADpj_TestParameter 796 * declaration is indicated the real type of 797 * the value, depending on the 798 * <code>parameterName</code>. 799 * 800 * @return ::BD_PJ_OK if the function has been 801 * performed successfully, otherwise return 802 * an error (refer to ::bdIMADpj_Status). 803 */ 804 BDIMADPJ_API bdIMADpj_Status bdIMADpj_getTestParameter(bdIMADpj bdIMADInstance, bdIMADpj_TestParameter parameterName, bdIMADpj_DirPath directionPath, void* pValue); 805 806 /** 807 * @brief Is used to get the VU meter level value located at the input/output 808 * of the send/receive path of the bdIMAD object pointed by the 809 * <code>pBdIMADInstance</code>. 810 * 811 * @param[in] bdIMADInstance bdIMAD object. 812 * 813 * @param[in] directionPath Indicates the send/receive direction path. 814 * The level value will be get from 815 * the VU meter located in the selected path. 816 * 817 * @param[in] side Indicates the input/output side. 818 * The level value will be get from 819 * the VU meter located at the selected 820 * side of the selected path. 821 * 822 * @param[out] *pValue Is a pointer to the float level value to be get. 823 * 824 * @return ::BD_PJ_OK if the function has been 825 * performed successfully, otherwise return 826 * an error (refer to ::bdIMADpj_Status). 827 */ 828 BDIMADPJ_API bdIMADpj_Status bdIMADpj_getVuMeterLevelValue(bdIMADpj bdIMADInstance, bdIMADpj_DirPath directionPath, bdIMADpj_Side side, float* pValue); 829 830 /** 831 * @brief Is used to enable/disable socket communication with GUI of the bdIMAD object pointed by the 832 * <code>pBdIMADInstance</code>. 833 * 834 * @param[in] bdIMADInstance bdIMAD object. 835 * 836 * @param[in] port Receive port number to be used for socket communication (bdController). 837 * 838 * @param[in] enable Set 1 to enable, 0 to disable the socket communication [default=disabled]. 839 * 840 * @return ::BD_PJ_OK if the function has been 841 * performed successfully, otherwise return 842 * an error (refer to ::bdIMADpj_Status). 843 */ 844 BDIMADPJ_API bdIMADpj_Status bdIMADpj_enableGuiSocketCommunication(bdIMADpj bdIMADInstance, int port, int enable); 845 555 846 /** 556 847 * @brief Is used to set the route of the output device of the bdIMAD object pointed by the 557 848 * <code>pBdIMADInstance</code>. 558 * @param[in] bdIMADInstance bdIMAD object. 559 * @param[in] outputRoute Indicate the route of the output device to set. 560 * @param[out] **ppWarningMessages Pointer to pointer to a 561 * ::bdIMADpj_Warnings_t structure, 562 * which reports the warnings after the 563 * set function. 564 * @return ::BD_PJ_OK if the function has been 565 * performed successfully, otherwise return 566 * an error (refer to ::bdIMADpj_Status). 849 * 850 * @param[in] bdIMADInstance bdIMAD object. 851 * 852 * @param[in] outputRoute Indicates the route of the output device to be set. 853 * 854 * @param[out] **ppWarningMessages Pointer to pointer to a 855 * ::bdIMADpj_Warnings_t structure, 856 * which reports the warnings after the 857 * set function. 858 * 859 * @return ::BD_PJ_OK if the function has been 860 * performed successfully, otherwise return 861 * an error (refer to ::bdIMADpj_Status). 567 862 */ 568 863 BDIMADPJ_API bdIMADpj_Status bdIMADpj_setRouteOutputDevice(bdIMADpj bdIMADInstance, bdIMADpj_out_dev_route outputRoute, bdIMADpj_Warnings_t **ppWarningMessages); … … 571 866 * @brief Is used to get the route of the output device of the bdIMAD object pointed by the 572 867 * <code>pBdIMADInstance</code>. 573 * @param[in] bdIMADInstance bdIMAD object. 574 * @param[out] *outputRoute Is a pointer to the route of the output device currently setted. 575 * @return ::BD_PJ_OK if the function has been 576 * performed successfully, otherwise return 577 * an error (refer to ::bdIMADpj_Status). 578 */ 868 * 869 * @param[in] bdIMADInstance bdIMAD object. 870 * 871 * @param[out] *outputRoute Pointer to the route of the output device currently set. 872 * 873 * @return ::BD_PJ_OK if the function has been 874 * performed successfully, otherwise return 875 * an error (refer to ::bdIMADpj_Status). 876 */ 877 579 878 BDIMADPJ_API bdIMADpj_Status bdIMADpj_getRouteOutputDevice(bdIMADpj bdIMADInstance, bdIMADpj_out_dev_route *outputRoute); 879 880 /** 881 * @brief Is used to get the device capabilities of capture/playback device of the bdIMAD object pointed by the 882 * <code>pBdIMADInstance</code>. 883 * 884 * @param[in] captureDevice Set to 1 to get the capabilities of capture 885 * devices. Set to 0 to get the capabilities of 886 * play devices. 887 * 888 * @caps[out] *caps Is a pointer to the device capabilities, 889 * as bitmask combination of #pjmedia_aud_dev_cap. 890 * 891 * @return ::BD_PJ_OK if the function has been 892 * performed successfully, otherwise return 893 * an error (refer to ::bdIMADpj_Status). 894 */ 895 BDIMADPJ_API bdIMADpj_Status bdIMADpj_getDeviceCapabilities(int captureDevice, unsigned *caps); 580 896 581 897 #ifdef __cplusplus
Note: See TracChangeset
for help on using the changeset viewer.