1 /* 2 * Copyright (C) 2004-2010 NXP Software 3 * Copyright (C) 2010 The Android Open Source Project 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 /****************************************************************************************/ 19 /* */ 20 /* Header file for the application layer interface of Concert Sound, Bass Enhancement, */ 21 /* Equalizer, Power Spectrum Analyzer, Trebble Enhancement and volume management */ 22 /* bundle. */ 23 /* */ 24 /* This files includes all definitions, types, structures and function */ 25 /* prototypes required by the calling layer. All other types, structures and */ 26 /* functions are private. */ 27 /* */ 28 /****************************************************************************************/ 29 /* */ 30 /* Note: 1 */ 31 /* ======= */ 32 /* The algorithm can execute either with separate input and output buffers or with */ 33 /* a common buffer, i.e. the data is processed in-place. */ 34 /* */ 35 /****************************************************************************************/ 36 /* */ 37 /* Note: 2 */ 38 /* ======= */ 39 /* Three data formats are support Stereo,Mono-In-Stereo and Mono. The data is */ 40 /* interleaved as follows: */ 41 /* */ 42 /* Byte Offset Stereo Input Mono-In-Stereo Input Mono Input */ 43 /* =========== ============ ==================== ============== */ 44 /* 0 Left Sample #1 Mono Sample #1 Mono Sample #1 */ 45 /* 2 Right Sample #1 Mono Sample #1 Mono Sample #2 */ 46 /* 4 Left Sample #2 Mono Sample #2 Mono Sample #3 */ 47 /* 6 Right Sample #2 Mono Sample #2 Mono Sample #4 */ 48 /* . . . . */ 49 /* . . . . */ 50 /* */ 51 /****************************************************************************************/ 52 53 #ifndef __LVM_H__ 54 #define __LVM_H__ 55 56 #ifdef __cplusplus 57 extern "C" { 58 #endif /* __cplusplus */ 59 60 61 /****************************************************************************************/ 62 /* */ 63 /* Includes */ 64 /* */ 65 /****************************************************************************************/ 66 67 #include "LVM_Types.h" 68 69 70 /****************************************************************************************/ 71 /* */ 72 /* Definitions */ 73 /* */ 74 /****************************************************************************************/ 75 76 /* Memory table*/ 77 #define LVM_NR_MEMORY_REGIONS 4 /* Number of memory regions */ 78 79 /* Concert Sound effect level presets */ 80 #define LVM_CS_EFFECT_NONE 0 /* 0% effect, minimum value */ 81 #define LVM_CS_EFFECT_LOW 16384 /* 50% effect */ 82 #define LVM_CS_EFFECT_MED 24576 /* 75% effect */ 83 #define LVM_CS_EFFECT_HIGH 32767 /* 100% effect, maximum value */ 84 85 /* Treble enhancement */ 86 #define LVM_TE_LOW_MIPS 32767 87 88 /* Bass enhancement effect level presets */ 89 #define LVM_BE_0DB 0 /* 0dB boost, no effect */ 90 #define LVM_BE_3DB 3 /* +3dB boost */ 91 #define LVM_BE_6DB 6 /* +6dB boost */ 92 #define LVM_BE_9DB 9 /* +9dB boost */ 93 #define LVM_BE_12DB 12 /* +12dB boost */ 94 #define LVM_BE_15DB 15 /* +15dB boost */ 95 96 /* N-Band Equalizer */ 97 #define LVM_EQ_NBANDS 5 /* Number of bands for equalizer */ 98 99 /* Headroom management */ 100 #define LVM_HEADROOM_MAX_NBANDS 5 101 102 /****************************************************************************************/ 103 /* */ 104 /* Types */ 105 /* */ 106 /****************************************************************************************/ 107 108 /* Instance handle */ 109 typedef void *LVM_Handle_t; 110 111 112 /* Status return values */ 113 typedef enum 114 { 115 LVM_SUCCESS = 0, /* Successful return from a routine */ 116 LVM_ALIGNMENTERROR = 1, /* Memory alignment error */ 117 LVM_NULLADDRESS = 2, /* NULL allocation address */ 118 LVM_OUTOFRANGE = 3, /* Out of range control parameter */ 119 LVM_INVALIDNUMSAMPLES = 4, /* Invalid number of samples */ 120 LVM_WRONGAUDIOTIME = 5, /* Wrong time value for audio time*/ 121 LVM_ALGORITHMDISABLED = 6, /* Algorithm is disabled*/ 122 LVM_ALGORITHMPSA = 7, /* Algorithm PSA returns an error */ 123 LVM_RETURNSTATUS_DUMMY = LVM_MAXENUM 124 } LVM_ReturnStatus_en; 125 126 127 /* Buffer Management mode */ 128 typedef enum 129 { 130 LVM_MANAGED_BUFFERS = 0, 131 LVM_UNMANAGED_BUFFERS = 1, 132 LVM_BUFFERS_DUMMY = LVM_MAXENUM 133 } LVM_BufferMode_en; 134 135 /* Output device type */ 136 typedef enum 137 { 138 LVM_HEADPHONES = 0, 139 LVM_EX_HEADPHONES = 1, 140 LVM_SPEAKERTYPE_MAX = LVM_MAXENUM 141 } LVM_OutputDeviceType_en; 142 143 /* Virtualizer mode selection*/ 144 typedef enum 145 { 146 LVM_CONCERTSOUND = 0, 147 LVM_VIRTUALIZERTYPE_DUMMY = LVM_MAXENUM 148 } LVM_VirtualizerType_en; 149 150 /* N-Band Equaliser operating mode */ 151 typedef enum 152 { 153 LVM_EQNB_OFF = 0, 154 LVM_EQNB_ON = 1, 155 LVM_EQNB_DUMMY = LVM_MAXENUM 156 } LVM_EQNB_Mode_en; 157 158 /* Bass Enhancement operating mode */ 159 typedef enum 160 { 161 LVM_BE_OFF = 0, 162 LVM_BE_ON = 1, 163 LVM_BE_DUMMY = LVM_MAXENUM 164 } LVM_BE_Mode_en; 165 166 /* Bass Enhancement centre frequency selection control */ 167 typedef enum 168 { 169 LVM_BE_CENTRE_55Hz = 0, 170 LVM_BE_CENTRE_66Hz = 1, 171 LVM_BE_CENTRE_78Hz = 2, 172 LVM_BE_CENTRE_90Hz = 3, 173 LVM_BE_CENTRE_DUMMY = LVM_MAXENUM 174 } LVM_BE_CentreFreq_en; 175 176 /* Bass Enhancement HPF selection control */ 177 typedef enum 178 { 179 LVM_BE_HPF_OFF = 0, 180 LVM_BE_HPF_ON = 1, 181 LVM_BE_HPF_DUMMY = LVM_MAXENUM 182 } LVM_BE_FilterSelect_en; 183 184 /* Volume Control operating mode */ 185 typedef enum 186 { 187 LVM_VC_OFF = 0, 188 LVM_VC_ON = 1, 189 LVM_VC_DUMMY = LVM_MAXENUM 190 } LVM_VC_Mode_en; 191 192 /* Treble Enhancement operating mode */ 193 typedef enum 194 { 195 LVM_TE_OFF = 0, 196 LVM_TE_ON = 1, 197 LVM_TE_DUMMY = LVM_MAXENUM 198 } LVM_TE_Mode_en; 199 200 /* Headroom management operating mode */ 201 typedef enum 202 { 203 LVM_HEADROOM_OFF = 0, 204 LVM_HEADROOM_ON = 1, 205 LVM_Headroom_DUMMY = LVM_MAXENUM 206 } LVM_Headroom_Mode_en; 207 208 typedef enum 209 { 210 LVM_PSA_SPEED_SLOW, /* Peak decaying at slow speed */ 211 LVM_PSA_SPEED_MEDIUM, /* Peak decaying at medium speed */ 212 LVM_PSA_SPEED_FAST, /* Peak decaying at fast speed */ 213 LVM_PSA_SPEED_DUMMY = LVM_MAXENUM 214 } LVM_PSA_DecaySpeed_en; 215 216 typedef enum 217 { 218 LVM_PSA_OFF = 0, 219 LVM_PSA_ON = 1, 220 LVM_PSA_DUMMY = LVM_MAXENUM 221 } LVM_PSA_Mode_en; 222 223 /* Version information */ 224 typedef struct 225 { 226 LVM_CHAR *pVersionNumber; /* Pointer to the version number in the format X.YY.ZZ */ 227 LVM_CHAR *pPlatform; /* Pointer to the library platform type */ 228 } LVM_VersionInfo_st; 229 230 231 /****************************************************************************************/ 232 /* */ 233 /* Structures */ 234 /* */ 235 /****************************************************************************************/ 236 237 /* Memory table containing the region definitions */ 238 typedef struct 239 { 240 LVM_MemoryRegion_st Region[LVM_NR_MEMORY_REGIONS]; /* One definition for each region */ 241 } LVM_MemTab_t; 242 243 /* N-Band equaliser band definition */ 244 typedef struct 245 { 246 LVM_INT16 Gain; /* Band gain in dB */ 247 LVM_UINT16 Frequency; /* Band centre frequency in Hz */ 248 LVM_UINT16 QFactor; /* Band quality factor (x100) */ 249 } LVM_EQNB_BandDef_t; 250 251 252 /* Headroom band definition */ 253 typedef struct 254 { 255 LVM_UINT16 Limit_Low; /* Low frequency limit of the band in Hertz */ 256 LVM_UINT16 Limit_High; /* High frequency limit of the band in Hertz */ 257 LVM_INT16 Headroom_Offset; /* Headroom = biggest band gain - Headroom_Offset */ 258 } LVM_HeadroomBandDef_t; 259 260 261 /* Control Parameter structure */ 262 typedef struct 263 { 264 /* General parameters */ 265 LVM_Mode_en OperatingMode; /* Bundle operating mode On/Bypass */ 266 LVM_Fs_en SampleRate; /* Sample rate */ 267 LVM_Format_en SourceFormat; /* Input data format */ 268 LVM_OutputDeviceType_en SpeakerType; /* Output device type */ 269 270 /* Concert Sound Virtualizer parameters*/ 271 LVM_Mode_en VirtualizerOperatingMode; /* Virtualizer operating mode On/Off */ 272 LVM_VirtualizerType_en VirtualizerType; /* Virtualizer type: ConcertSound */ 273 LVM_UINT16 VirtualizerReverbLevel; /* Virtualizer reverb level in % */ 274 LVM_INT16 CS_EffectLevel; /* Concert Sound effect level */ 275 276 /* N-Band Equaliser parameters */ 277 LVM_EQNB_Mode_en EQNB_OperatingMode; /* N-Band Equaliser operating mode */ 278 LVM_UINT16 EQNB_NBands; /* Number of bands */ 279 LVM_EQNB_BandDef_t *pEQNB_BandDefinition; /* Pointer to equaliser definitions */ 280 281 /* Bass Enhancement parameters */ 282 LVM_BE_Mode_en BE_OperatingMode; /* Bass Enhancement operating mode */ 283 LVM_INT16 BE_EffectLevel; /* Bass Enhancement effect level */ 284 LVM_BE_CentreFreq_en BE_CentreFreq; /* Bass Enhancement centre frequency */ 285 LVM_BE_FilterSelect_en BE_HPF; /* Bass Enhancement high pass filter selector */ 286 287 /* Volume Control parameters */ 288 LVM_INT16 VC_EffectLevel; /* Volume Control setting in dBs */ 289 LVM_INT16 VC_Balance; /* Left Right Balance control in dB (-96 to 96 dB), -ve values reduce 290 Right channel while +ve value reduces Left channel*/ 291 292 /* Treble Enhancement parameters */ 293 LVM_TE_Mode_en TE_OperatingMode; /* Treble Enhancement On/Off */ 294 LVM_INT16 TE_EffectLevel; /* Treble Enhancement gain dBs */ 295 296 /* Spectrum Analyzer parameters Control */ 297 LVM_PSA_Mode_en PSA_Enable; 298 LVM_PSA_DecaySpeed_en PSA_PeakDecayRate; /* Peak value decay rate*/ 299 #ifdef SUPPORT_MC 300 LVM_INT32 NrChannels; 301 LVM_INT32 ChMask; 302 #endif 303 304 } LVM_ControlParams_t; 305 306 307 /* Instance Parameter structure */ 308 typedef struct 309 { 310 /* General */ 311 LVM_BufferMode_en BufferMode; /* Buffer management mode */ 312 LVM_UINT16 MaxBlockSize; /* Maximum processing block size */ 313 314 /* N-Band Equaliser */ 315 LVM_UINT16 EQNB_NumBands; /* Maximum number of equaliser bands */ 316 317 /* PSA */ 318 LVM_PSA_Mode_en PSA_Included; /* Controls the instance memory allocation for PSA: ON/OFF */ 319 } LVM_InstParams_t; 320 321 /* Headroom management parameter structure */ 322 typedef struct 323 { 324 LVM_Headroom_Mode_en Headroom_OperatingMode; /* Headroom Control On/Off */ 325 LVM_HeadroomBandDef_t *pHeadroomDefinition; /* Pointer to headroom bands definition */ 326 LVM_UINT16 NHeadroomBands; /* Number of headroom bands */ 327 328 } LVM_HeadroomParams_t; 329 330 /****************************************************************************************/ 331 /* */ 332 /* Function Prototypes */ 333 /* */ 334 /****************************************************************************************/ 335 336 337 /****************************************************************************************/ 338 /* */ 339 /* FUNCTION: LVM_GetVersionInfo */ 340 /* */ 341 /* DESCRIPTION: */ 342 /* This function is used to retrieve information about the library's version. */ 343 /* */ 344 /* PARAMETERS: */ 345 /* pVersion Pointer to an empty version info structure */ 346 /* */ 347 /* RETURNS: */ 348 /* LVM_SUCCESS Succeeded */ 349 /* LVM_NULLADDRESS when pVersion is NULL */ 350 /* */ 351 /* NOTES: */ 352 /* 1. This function may be interrupted by the LVM_Process function */ 353 /* */ 354 /****************************************************************************************/ 355 LVM_ReturnStatus_en LVM_GetVersionInfo(LVM_VersionInfo_st *pVersion); 356 357 358 /****************************************************************************************/ 359 /* */ 360 /* FUNCTION: LVM_GetMemoryTable */ 361 /* */ 362 /* DESCRIPTION: */ 363 /* This function is used for memory allocation and free. It can be called in */ 364 /* two ways: */ 365 /* */ 366 /* hInstance = NULL Returns the memory requirements */ 367 /* hInstance = Instance handle Returns the memory requirements and */ 368 /* allocated base addresses for the instance */ 369 /* */ 370 /* When this function is called for memory allocation (hInstance=NULL) the memory */ 371 /* base address pointers are NULL on return. */ 372 /* */ 373 /* When the function is called for free (hInstance = Instance Handle) the memory */ 374 /* table returns the allocated memory and base addresses used during initialisation. */ 375 /* */ 376 /* PARAMETERS: */ 377 /* hInstance Instance Handle */ 378 /* pMemoryTable Pointer to an empty memory definition table */ 379 /* pInstParams Pointer to the instance parameters */ 380 /* */ 381 /* RETURNS: */ 382 /* LVM_SUCCESS Succeeded */ 383 /* LVM_NULLADDRESS When one of pMemoryTable or pInstParams is NULL */ 384 /* LVM_OUTOFRANGE When any of the Instance parameters are out of range */ 385 /* */ 386 /* NOTES: */ 387 /* 1. This function may be interrupted by the LVM_Process function */ 388 /* */ 389 /****************************************************************************************/ 390 LVM_ReturnStatus_en LVM_GetMemoryTable(LVM_Handle_t hInstance, 391 LVM_MemTab_t *pMemoryTable, 392 LVM_InstParams_t *pInstParams); 393 394 395 /****************************************************************************************/ 396 /* */ 397 /* FUNCTION: LVM_GetInstanceHandle */ 398 /* */ 399 /* DESCRIPTION: */ 400 /* This function is used to create a bundle instance. It returns the created instance */ 401 /* handle through phInstance. All parameters are set to their default, inactive state. */ 402 /* */ 403 /* PARAMETERS: */ 404 /* phInstance pointer to the instance handle */ 405 /* pMemoryTable Pointer to the memory definition table */ 406 /* pInstParams Pointer to the instance parameters */ 407 /* */ 408 /* RETURNS: */ 409 /* LVM_SUCCESS Initialisation succeeded */ 410 /* LVM_NULLADDRESS One or more memory has a NULL pointer */ 411 /* LVM_OUTOFRANGE When any of the Instance parameters are out of range */ 412 /* */ 413 /* NOTES: */ 414 /* 1. This function must not be interrupted by the LVM_Process function */ 415 /* */ 416 /****************************************************************************************/ 417 LVM_ReturnStatus_en LVM_GetInstanceHandle(LVM_Handle_t *phInstance, 418 LVM_MemTab_t *pMemoryTable, 419 LVM_InstParams_t *pInstParams); 420 421 422 /****************************************************************************************/ 423 /* */ 424 /* FUNCTION: LVM_ClearAudioBuffers */ 425 /* */ 426 /* DESCRIPTION: */ 427 /* This function is used to clear the internal audio buffers of the bundle. */ 428 /* */ 429 /* PARAMETERS: */ 430 /* hInstance Instance handle */ 431 /* */ 432 /* RETURNS: */ 433 /* LVM_SUCCESS Initialisation succeeded */ 434 /* LVM_NULLADDRESS Instance memory has a NULL pointer */ 435 /* */ 436 /* NOTES: */ 437 /* 1. This function must not be interrupted by the LVM_Process function */ 438 /* */ 439 /****************************************************************************************/ 440 LVM_ReturnStatus_en LVM_ClearAudioBuffers(LVM_Handle_t hInstance); 441 442 443 /****************************************************************************************/ 444 /* */ 445 /* FUNCTION: LVM_GetControlParameters */ 446 /* */ 447 /* DESCRIPTION: */ 448 /* Request the LifeVibes module parameters. The current parameter set is returned */ 449 /* via the parameter pointer. */ 450 /* */ 451 /* PARAMETERS: */ 452 /* hInstance Instance handle */ 453 /* pParams Pointer to an empty parameter structure */ 454 /* */ 455 /* RETURNS: */ 456 /* LVM_SUCCESS Succeeded */ 457 /* LVM_NULLADDRESS when any of hInstance or pParams is NULL */ 458 /* */ 459 /* NOTES: */ 460 /* 1. This function may be interrupted by the LVM_Process function */ 461 /* */ 462 /****************************************************************************************/ 463 LVM_ReturnStatus_en LVM_GetControlParameters(LVM_Handle_t hInstance, 464 LVM_ControlParams_t *pParams); 465 466 467 /****************************************************************************************/ 468 /* */ 469 /* FUNCTION: LVM_SetControlParameters */ 470 /* */ 471 /* DESCRIPTION: */ 472 /* Sets or changes the LifeVibes module parameters. */ 473 /* */ 474 /* PARAMETERS: */ 475 /* hInstance Instance handle */ 476 /* pParams Pointer to a parameter structure */ 477 /* */ 478 /* RETURNS: */ 479 /* LVM_SUCCESS Succeeded */ 480 /* LVM_NULLADDRESS When hInstance, pParams or any control pointers are NULL */ 481 /* LVM_OUTOFRANGE When any of the control parameters are out of range */ 482 /* */ 483 /* NOTES: */ 484 /* 1. This function may be interrupted by the LVM_Process function */ 485 /* */ 486 /****************************************************************************************/ 487 LVM_ReturnStatus_en LVM_SetControlParameters(LVM_Handle_t hInstance, 488 LVM_ControlParams_t *pParams); 489 490 491 /****************************************************************************************/ 492 /* */ 493 /* FUNCTION: LVM_Process */ 494 /* */ 495 /* DESCRIPTION: */ 496 /* Process function for the LifeVibes module. */ 497 /* */ 498 /* PARAMETERS: */ 499 /* hInstance Instance handle */ 500 /* pInData Pointer to the input data */ 501 /* pOutData Pointer to the output data */ 502 /* NumSamples Number of samples in the input buffer */ 503 /* AudioTime Audio Time of the current input data in milli-seconds */ 504 /* */ 505 /* RETURNS: */ 506 /* LVM_SUCCESS Succeeded */ 507 /* LVM_INVALIDNUMSAMPLES When the NumSamples is not a valied multiple in unmanaged */ 508 /* buffer mode */ 509 /* LVM_ALIGNMENTERROR When either the input our output buffers are not 32-bit */ 510 /* aligned in unmanaged mode */ 511 /* LVM_NULLADDRESS When one of hInstance, pInData or pOutData is NULL */ 512 /* */ 513 /* NOTES: */ 514 /* 1. The input and output buffers must be 32-bit aligned */ 515 /* 2. Number of samples is defined as follows: */ 516 /* MONO the number of samples in the block */ 517 /* MONOINSTEREO the number of sample pairs in the block */ 518 /* STEREO the number of sample pairs in the block */ 519 /* */ 520 /****************************************************************************************/ 521 #ifdef BUILD_FLOAT 522 LVM_ReturnStatus_en LVM_Process(LVM_Handle_t hInstance, 523 const LVM_FLOAT *pInData, 524 LVM_FLOAT *pOutData, 525 LVM_UINT16 NumSamples, 526 LVM_UINT32 AudioTime); 527 #else 528 LVM_ReturnStatus_en LVM_Process(LVM_Handle_t hInstance, 529 const LVM_INT16 *pInData, 530 LVM_INT16 *pOutData, 531 LVM_UINT16 NumSamples, 532 LVM_UINT32 AudioTime); 533 #endif 534 535 536 /****************************************************************************************/ 537 /* */ 538 /* FUNCTION: LVM_SetHeadroomParams */ 539 /* */ 540 /* DESCRIPTION: */ 541 /* This function is used to set the automatic headroom management parameters. */ 542 /* */ 543 /* PARAMETERS: */ 544 /* hInstance Instance Handle */ 545 /* pHeadroomParams Pointer to headroom parameter structure */ 546 /* */ 547 /* RETURNS: */ 548 /* LVM_NULLADDRESS When hInstance or pHeadroomParams is NULL */ 549 /* LVM_SUCCESS Succeeded */ 550 /* */ 551 /* NOTES: */ 552 /* 1. This function may be interrupted by the LVM_Process function */ 553 /* */ 554 /****************************************************************************************/ 555 LVM_ReturnStatus_en LVM_SetHeadroomParams( LVM_Handle_t hInstance, 556 LVM_HeadroomParams_t *pHeadroomParams); 557 558 559 /****************************************************************************************/ 560 /* */ 561 /* FUNCTION: LVM_GetHeadroomParams */ 562 /* */ 563 /* DESCRIPTION: */ 564 /* This function is used to get the automatic headroom management parameters. */ 565 /* */ 566 /* PARAMETERS: */ 567 /* hInstance Instance Handle */ 568 /* pHeadroomParams Pointer to headroom parameter structure (output) */ 569 /* */ 570 /* RETURNS: */ 571 /* LVM_SUCCESS Succeeded */ 572 /* LVM_NULLADDRESS When hInstance or pHeadroomParams are NULL */ 573 /* */ 574 /* NOTES: */ 575 /* 1. This function may be interrupted by the LVM_Process function */ 576 /* */ 577 /****************************************************************************************/ 578 LVM_ReturnStatus_en LVM_GetHeadroomParams( LVM_Handle_t hInstance, 579 LVM_HeadroomParams_t *pHeadroomParams); 580 581 582 /****************************************************************************************/ 583 /* */ 584 /* FUNCTION: LVM_GetSpectrum */ 585 /* */ 586 /* DESCRIPTION: */ 587 /* This function is used to retrieve Spectral information at a given Audio time */ 588 /* for display usage */ 589 /* */ 590 /* PARAMETERS: */ 591 /* hInstance Instance Handle */ 592 /* pCurrentPeaks Pointer to location where currents peaks are to be saved */ 593 /* pPastPeaks Pointer to location where past peaks are to be saved */ 594 /* pCentreFreqs Pointer to location where centre frequency of each band is */ 595 /* to be saved */ 596 /* AudioTime Audio time at which the spectral information is needed */ 597 /* */ 598 /* RETURNS: */ 599 /* LVM_SUCCESS Succeeded */ 600 /* LVM_NULLADDRESS If any of input addresses are NULL */ 601 /* LVM_WRONGAUDIOTIME Failure due to audio time error */ 602 /* */ 603 /* NOTES: */ 604 /* 1. This function may be interrupted by the LVM_Process function */ 605 /* */ 606 /****************************************************************************************/ 607 LVM_ReturnStatus_en LVM_GetSpectrum( LVM_Handle_t hInstance, 608 LVM_UINT8 *pCurrentPeaks, 609 LVM_UINT8 *pPastPeaks, 610 LVM_INT32 AudioTime); 611 612 /****************************************************************************************/ 613 /* */ 614 /* FUNCTION: LVM_SetVolumeNoSmoothing */ 615 /* */ 616 /* DESCRIPTION: */ 617 /* This function is used to set output volume without any smoothing */ 618 /* */ 619 /* PARAMETERS: */ 620 /* hInstance Instance Handle */ 621 /* pParams Control Parameters, only volume value is used here */ 622 /* */ 623 /* RETURNS: */ 624 /* LVM_SUCCESS Succeeded */ 625 /* LVM_NULLADDRESS If any of input addresses are NULL */ 626 /* LVM_OUTOFRANGE When any of the control parameters are out of range */ 627 /* */ 628 /* NOTES: */ 629 /* 1. This function may be interrupted by the LVM_Process function */ 630 /* */ 631 /****************************************************************************************/ 632 LVM_ReturnStatus_en LVM_SetVolumeNoSmoothing( LVM_Handle_t hInstance, 633 LVM_ControlParams_t *pParams); 634 635 636 #ifdef __cplusplus 637 } 638 #endif /* __cplusplus */ 639 640 #endif /* __LVM_H__ */ 641 642