⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mp3dec_pmp3_dec.h

📁 瑞星微公司RK27XX系列芯片的SDK开发包
💻 H
字号:


#if 1
extern AudioDecoder MP3DecoderHPQ;
#else
static AudioDecoder MP3DecoderHPQ;
#endif


#ifndef _MPGDATA_H_
#define _MPGDATA_H_

/*******************************************************************
* NOTE: The instance data MUST be aligned on a 2048-byte boundary. *
* One instance has already been defined. This should be adequate   *
* for most applications.                                           *
*******************************************************************/


typedef char tmInstance[11000];
typedef char tmScratch[5292];

extern tmInstance mInstance;
extern tmScratch mScratch;

#endif

#define SEEK_BY_BYTES 1
#define SEEK_BY_TIME  2
#define MP3_MAX_PCM_LENGTH 1152

typedef struct tagDecoderList
{
    const AudioDecoder   *Decoder ;
    char                 *descript;
    char                 *extensions;

    sDecoderFormats      formats[1];

    sDecoderRequirements requirements[1];

    oDecoderHandle       *handle;

    void                 *instancestate;
    void                 *scratch;
} DecoderList ;

extern DecoderList AudioDecoders[];

/* Typedefs */

#define MP3_PCM_BUFFER_SIZE  (MP3_MAX_PCM_LENGTH * 3)
#define MP3_ENCODED_DATA_SIZE  (2048)


#define pENCODED_DATA  (pMP3->pcEncodedData)


typedef struct
{

    DecoderList *workspace;
    eDecoderStatus status;
    sDecoderBitstream bitstream;
    sDecoderOutput output;

    tmInstance *pmInstance;
    tmScratch *pmScratch;


    char pcEncodedData[MP3_ENCODED_DATA_SIZE];


    short psLeft[MP3_PCM_BUFFER_SIZE];
    short psRight[MP3_PCM_BUFFER_SIZE];

    BufferState *pOutput;
    int buffer_ptr[2];

    unsigned short usValid;

    unsigned short usSampleRate;

    unsigned char ucChannels;

    unsigned char ucIsVBR;

    unsigned long ulFirstFrame;

    unsigned long ulLength;

    unsigned long ulTimeLength;

    unsigned long ulBitRate;

    unsigned long ulTimePos;

} tMP3;


⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -