Mercurial > audlegacy
comparison Plugins/Input/aac/libfaad2/decoder.h @ 199:0a2ad94e8607 trunk
[svn] Synced with bmp-mp4. Build system is fragile, but should work now.
author | chainsaw |
---|---|
date | Wed, 16 Nov 2005 16:21:11 -0800 |
parents | fa848bd484d8 |
children | 29feaace84d0 |
comparison
equal
deleted
inserted
replaced
198:5a338b31e393 | 199:0a2ad94e8607 |
---|---|
1 /* | 1 /* |
2 ** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding | 2 ** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding |
3 ** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com | 3 ** Copyright (C) 2003-2004 M. Bakker, Ahead Software AG, http://www.nero.com |
4 ** | 4 ** |
5 ** This program is free software; you can redistribute it and/or modify | 5 ** This program is free software; you can redistribute it and/or modify |
6 ** it under the terms of the GNU General Public License as published by | 6 ** it under the terms of the GNU General Public License as published by |
7 ** the Free Software Foundation; either version 2 of the License, or | 7 ** the Free Software Foundation; either version 2 of the License, or |
8 ** (at your option) any later version. | 8 ** (at your option) any later version. |
20 ** forbidden. | 20 ** forbidden. |
21 ** | 21 ** |
22 ** Commercial non-GPL licensing of this software is possible. | 22 ** Commercial non-GPL licensing of this software is possible. |
23 ** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. | 23 ** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. |
24 ** | 24 ** |
25 ** $Id: decoder.h,v 1.33 2003/11/12 20:47:57 menno Exp $ | 25 ** $Id: decoder.h,v 1.44 2004/09/04 14:56:28 menno Exp $ |
26 **/ | 26 **/ |
27 | 27 |
28 #ifndef __DECODER_H__ | 28 #ifndef __DECODER_H__ |
29 #define __DECODER_H__ | 29 #define __DECODER_H__ |
30 | 30 |
32 extern "C" { | 32 extern "C" { |
33 #endif | 33 #endif |
34 | 34 |
35 #ifdef _WIN32 | 35 #ifdef _WIN32 |
36 #pragma pack(push, 8) | 36 #pragma pack(push, 8) |
37 #ifndef FAADAPI | 37 #ifndef NEAACDECAPI |
38 #define FAADAPI __cdecl | 38 #define NEAACDECAPI __cdecl |
39 #endif | 39 #endif |
40 #else | 40 #else |
41 #ifndef FAADAPI | 41 #ifndef NEAACDECAPI |
42 #define FAADAPI | 42 #define NEAACDECAPI |
43 #endif | 43 #endif |
44 #endif | 44 #endif |
45 | |
46 #include "bits.h" | |
47 #include "syntax.h" | |
48 #include "drc.h" | |
49 #include "specrec.h" | |
50 #include "filtbank.h" | |
51 #include "ic_predict.h" | |
52 | 45 |
53 | 46 |
54 /* library output formats */ | 47 /* library output formats */ |
55 #define FAAD_FMT_16BIT 1 | 48 #define FAAD_FMT_16BIT 1 |
56 #define FAAD_FMT_24BIT 2 | 49 #define FAAD_FMT_24BIT 2 |
57 #define FAAD_FMT_32BIT 3 | 50 #define FAAD_FMT_32BIT 3 |
58 #define FAAD_FMT_FLOAT 4 | 51 #define FAAD_FMT_FLOAT 4 |
52 #define FAAD_FMT_FIXED FAAD_FMT_FLOAT | |
59 #define FAAD_FMT_DOUBLE 5 | 53 #define FAAD_FMT_DOUBLE 5 |
60 | 54 |
61 #define LC_DEC_CAP (1<<0) | 55 #define LC_DEC_CAP (1<<0) |
62 #define MAIN_DEC_CAP (1<<1) | 56 #define MAIN_DEC_CAP (1<<1) |
63 #define LTP_DEC_CAP (1<<2) | 57 #define LTP_DEC_CAP (1<<2) |
74 #define BACK_CHANNEL_RIGHT (7) | 68 #define BACK_CHANNEL_RIGHT (7) |
75 #define BACK_CHANNEL_CENTER (8) | 69 #define BACK_CHANNEL_CENTER (8) |
76 #define LFE_CHANNEL (9) | 70 #define LFE_CHANNEL (9) |
77 #define UNKNOWN_CHANNEL (0) | 71 #define UNKNOWN_CHANNEL (0) |
78 | 72 |
79 int8_t* FAADAPI faacDecGetErrorMessage(uint8_t errcode); | 73 char* NEAACDECAPI NeAACDecGetErrorMessage(uint8_t errcode); |
80 | 74 |
81 uint32_t FAADAPI faacDecGetCapabilities(); | 75 uint32_t NEAACDECAPI NeAACDecGetCapabilities(void); |
82 | 76 |
83 faacDecHandle FAADAPI faacDecOpen(); | 77 NeAACDecHandle NEAACDECAPI NeAACDecOpen(void); |
84 | 78 |
85 faacDecConfigurationPtr FAADAPI faacDecGetCurrentConfiguration(faacDecHandle hDecoder); | 79 NeAACDecConfigurationPtr NEAACDECAPI NeAACDecGetCurrentConfiguration(NeAACDecHandle hDecoder); |
86 | 80 |
87 uint8_t FAADAPI faacDecSetConfiguration(faacDecHandle hDecoder, | 81 uint8_t NEAACDECAPI NeAACDecSetConfiguration(NeAACDecHandle hDecoder, |
88 faacDecConfigurationPtr config); | 82 NeAACDecConfigurationPtr config); |
89 | 83 |
90 /* Init the library based on info from the AAC file (ADTS/ADIF) */ | 84 /* Init the library based on info from the AAC file (ADTS/ADIF) */ |
91 int32_t FAADAPI faacDecInit(faacDecHandle hDecoder, | 85 int32_t NEAACDECAPI NeAACDecInit(NeAACDecHandle hDecoder, |
92 uint8_t *buffer, | 86 uint8_t *buffer, |
93 uint32_t buffer_size, | 87 uint32_t buffer_size, |
94 uint32_t *samplerate, | 88 uint32_t *samplerate, |
95 uint8_t *channels); | 89 uint8_t *channels); |
96 | 90 |
97 /* Init the library using a DecoderSpecificInfo */ | 91 /* Init the library using a DecoderSpecificInfo */ |
98 int8_t FAADAPI faacDecInit2(faacDecHandle hDecoder, uint8_t *pBuffer, | 92 int8_t NEAACDECAPI NeAACDecInit2(NeAACDecHandle hDecoder, uint8_t *pBuffer, |
99 uint32_t SizeOfDecoderSpecificInfo, | 93 uint32_t SizeOfDecoderSpecificInfo, |
100 uint32_t *samplerate, uint8_t *channels); | 94 uint32_t *samplerate, uint8_t *channels); |
101 | 95 |
102 /* Init the library for DRM */ | 96 /* Init the library for DRM */ |
103 int8_t FAADAPI faacDecInitDRM(faacDecHandle hDecoder, uint32_t samplerate, | 97 int8_t NEAACDECAPI NeAACDecInitDRM(NeAACDecHandle *hDecoder, uint32_t samplerate, |
104 uint8_t channels); | 98 uint8_t channels); |
105 | 99 |
106 void FAADAPI faacDecClose(faacDecHandle hDecoder); | 100 void NEAACDECAPI NeAACDecClose(NeAACDecHandle hDecoder); |
107 | 101 |
108 void FAADAPI faacDecPostSeekReset(faacDecHandle hDecoder, int32_t frame); | 102 void NEAACDECAPI NeAACDecPostSeekReset(NeAACDecHandle hDecoder, int32_t frame); |
109 | 103 |
110 void* FAADAPI faacDecDecode(faacDecHandle hDecoder, | 104 void* NEAACDECAPI NeAACDecDecode(NeAACDecHandle hDecoder, |
111 faacDecFrameInfo *hInfo, | 105 NeAACDecFrameInfo *hInfo, |
112 uint8_t *buffer, | 106 uint8_t *buffer, |
113 uint32_t buffer_size); | 107 uint32_t buffer_size); |
108 | |
109 void* NEAACDECAPI NeAACDecDecode2(NeAACDecHandle hDecoder, | |
110 NeAACDecFrameInfo *hInfo, | |
111 uint8_t *buffer, uint32_t buffer_size, | |
112 void **sample_buffer, uint32_t sample_buffer_size); | |
114 | 113 |
115 #ifdef _WIN32 | 114 #ifdef _WIN32 |
116 #pragma pack(pop) | 115 #pragma pack(pop) |
117 #endif | 116 #endif |
118 | 117 |