32#define LC3_ERROR_OFFSET (-5000)
33#define LC3_RESULT_NO_ERROR (0)
34#define LC3_RESULT_INVALID_PARAMETER ((LC3_ERROR_OFFSET)-1)
35#define LC3_RESULT_INSUFFICIENT_RESOURCES ((LC3_ERROR_OFFSET)-2)
36#define LC3_RESULT_NOT_INITIALIZED ((LC3_ERROR_OFFSET)-3)
37#define LC3_RESULT_UNKNOWN_ERROR ((LC3_ERROR_OFFSET)-4)
38#define LC3_RESULT_INVALID_BITRATE ((LC3_ERROR_OFFSET)-5)
39#define LC3_RESULT_INPUT_BUFFER_TOO_SMALL ((LC3_ERROR_OFFSET)-6)
40#define LC3_RESULT_OUTPUT_BUFFER_TOO_SMALL ((LC3_ERROR_OFFSET)-7)
41#define LC3_RESULT_INVALID_BITSPERSAMPLE ((LC3_ERROR_OFFSET)-8)
42#define LC3_RESULT_INVALID_SAMPLERATE ((LC3_ERROR_OFFSET)-9)
43#define LC3_RESULT_BITERRORCONDITION ((LC3_ERROR_OFFSET)-10)
44#define LC3_RESULT_FEATURE_NOT_SUPPORTED ((LC3_ERROR_OFFSET)-11)
45#define LC3_RESULT_STILL_IN_USE ((LC3_ERROR_OFFSET)-12)
46#define LC3_RESULT_ALREADY_INITIALIZED ((LC3_ERROR_OFFSET)-13)
52#define LC3_SAMPLE_RATE_NONE (0x00)
53#define LC3_SAMPLE_RATE_8_KHZ (0x01)
54#define LC3_SAMPLE_RATE_16_KHZ (0x02)
55#define LC3_SAMPLE_RATE_24_KHZ (0x04)
56#define LC3_SAMPLE_RATE_32_KHZ (0x08)
57#define LC3_SAMPLE_RATE_441_KHZ (0x10)
58#define LC3_SAMPLE_RATE_48_KHZ (0x20)
59#define LC3_SAMPLE_RATE_ALL (0x1F)
void LC3DecodeSessionClose(LC3DecoderHandle_t decodeHandle)
Closes an LC3 Decoder session.
uint16_t LC3PCMBuffersize(uint16_t sampleRate, uint8_t bitDepth, LC3FrameSize_t frameSize, int32_t *result)
Calculates the buffer size required for PCM data.
LC3FrameSize_t
Session Frame Size.
Definition: LC3API.h:90
@ LC3FrameSize10Ms
10 msec frame size.
Definition: LC3API.h:91
@ LC3FrameSize7_5Ms
7.5 msec frame size.
Definition: LC3API.h:92
int32_t LC3EncodeSessionData(LC3EncoderHandle_t encodeHandle, LC3EncodeInput_t *encodeInput, LC3EncodeOutput_t *encodeOutput)
Encodes a frame of data using LC3.
int32_t LC3DecodeSessionData(LC3DecoderHandle_t decodeHandle, LC3DecodeInput_t *decodeInput, LC3DecodeOutput_t *decodeOutput)
Decodes a frame of data using LC3.
uint16_t LC3BitstreamBuffersize(uint16_t sampleRate, uint32_t maxBitRate, LC3FrameSize_t frameSize, int32_t *result)
Calculates the buffer size required for bit stream data.
int32_t LC3Deinitialize(void)
Deinitializes the LC3 Codec.
LC3DecoderHandle_t LC3DecodeSessionOpen(uint16_t sampleRate, uint8_t bitsPerSample, LC3FrameSize_t frameSize, uint8_t *buffer, uint16_t *bufferSize, int32_t *result)
Opens and initializes an LC3 Decoder session.
void * LC3DecoderHandle_t
LC3 decoder handle type.
Definition: LC3API.h:70
void * LC3EncoderHandle_t
LC3 encoder handle type.
Definition: LC3API.h:67
LC3BFI_t
Bad Frame Indicator (BFI).
Definition: LC3API.h:137
@ BadFrame
Definition: LC3API.h:139
@ GoodFrame
Definition: LC3API.h:138
LC3FrameSizeConfig_t
Frame Size for configuration.
Definition: LC3API.h:79
@ LC3FrameSizeBothConfig
7.5 and 10 msec frame size.
Definition: LC3API.h:82
@ LC3FrameSize7_5MsConfig
7.5 msec frame size.
Definition: LC3API.h:81
@ LC3FrameSize10MsConfig
10 msec frame size.
Definition: LC3API.h:80
void LC3EncodeSessionClose(LC3EncoderHandle_t encodeHandle)
Closes an LC3 Encoder session.
LC3EncoderHandle_t LC3EncodeSessionOpen(uint16_t sampleRate, uint8_t bitsPerSample, LC3FrameSize_t frameSize, uint8_t *buffer, uint16_t *bufferSize, int32_t *result)
Opens and initializes an LC3 Encoder session.
int32_t LC3Initialize(uint8_t encoderSampleRates, uint8_t decoderSampleRates, LC3FrameSizeConfig_t frameSizeConfig, uint8_t uniqueSessions, uint8_t *buffer, uint32_t *bufferSize)
Initializes the LC3 Codec.
#define OSALCALL
OSAL calling convention.
Definition: osal_types.h:15
uint16_t PLCCounter
Number of successive frames to which PLC has been applied.
Definition: LC3API.h:172
uint16_t PCMDataLength
Output buffer size in bytes.
Definition: LC3API.h:170
void * PCMData
Output buffer pointer.
Definition: LC3API.h:169
uint16_t bytesWritten
Number of bytes written to the output buffer.
Definition: LC3API.h:171
LC3 decoder output PCM structure.
Definition: LC3API.h:168
uint16_t outputDataLength
Output buffer size in bytes.
Definition: LC3API.h:122
uint8_t * outputData
Output buffer pointer.
Definition: LC3API.h:121
uint16_t bytesWritten
Number of bit stream bytes written.
Definition: LC3API.h:123
LC3 encoder output data structure.
Definition: LC3API.h:120