123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160 |
- #ifndef __MP4AUDIODECIFC_H__
- #define __MP4AUDIODECIFC_H__
- #include "mp4dec_helpers/err_code.h"
- #include "mp4dec_asc/audiospecificconfig_c.h"
- #include "mp4dec_helpers/usrparam.h"
- #include "mp4dec_helpers/aubuffer_c.h"
- #include "mp4dec_helpers/cubuffer_c.h"
- #ifdef __cplusplus
- extern "C" {
- #endif
- #if defined(WIN32) || defined(WIN64)
- #pragma pack(push, 8)
- #endif
- typedef struct mp4AudioDecoder_VersionInfo {
- char dateTime[80];
- char versionNo[40];
- char options[1024];
- char options_ext[4096];
- } mp4AudioDecoder_VersionInfo;
- struct mp4AudioDecoder;
- typedef struct mp4AudioDecoder* mp4AudioDecoderHandle;
- mp4AudioDecoderHandle MP4AUDIODECAPI mp4AudioDecoder_Create(
- const struct CSAudioSpecificConfig * const asc[],
- const unsigned int noOfLayers
- );
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_SetParam(
- const mp4AudioDecoderHandle self,
- const unsigned int param,
- const float value
- );
-
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_DecodeFrame(
- mp4AudioDecoderHandle self,
- struct CAccessUnit* auBuffer[],
- struct CCompositionUnit* cuBuffer
- );
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_Destroy(mp4AudioDecoderHandle* self);
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_Reset(
- mp4AudioDecoderHandle self,
- const unsigned int param,
- int value
- );
-
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_Flush(
- mp4AudioDecoderHandle self,
- struct CCompositionUnit* cuBuffer
- );
-
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_GetBufferFullness(
- const mp4AudioDecoderHandle self,
- const unsigned int layer,
- unsigned int* bufferfullness
- );
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_GetSamplesPerFrame(
- const mp4AudioDecoderHandle self,
- unsigned int* spf
- );
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_SetOutputLayer(
- const mp4AudioDecoderHandle self,
- const unsigned int outputLayer
- );
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_GetLastError(const mp4AudioDecoderHandle self);
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_GetLibraryVersion(mp4AudioDecoder_VersionInfo* versionInfo);
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_ascParse(
- const unsigned char* decSpecificInfoBuf,
- const unsigned int decSpecificInfoBuf_len,
- struct CSAudioSpecificConfig* asc
- );
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_ascParseStream(
- const unsigned char* decSpecificInfoBuf,
- struct CSAudioSpecificConfig* asc,
- int* bitsRead
- );
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_ascParseExt(
- const unsigned char* const decSpecificInfoBuf[],
- const unsigned int decSpecificInfoBuf_len[],
- const unsigned int avgBitrate[],
- const unsigned int streams,
- unsigned int* layers,
- struct CSAudioSpecificConfig* asc[],
- unsigned int streamsPerLayer[]
- );
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_ascPrint(
- unsigned int layers,
- struct CSAudioSpecificConfig* asc[],
- unsigned int stringLen,
- unsigned char string[]
- );
- MP4_RESULT MP4AUDIODECAPI mp4AudioDecoder_GetPcmWidth(
- const unsigned char* const decSpecificInfoBuf[],
- const unsigned int decSpecificInfoBuf_len[],
- const unsigned int streams,
- unsigned int* pcmwidth
- );
- #if defined(WIN32) || defined(WIN64)
- #pragma pack(pop)
- #endif
- #ifdef __cplusplus
- }
- #endif
- #endif
|