| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
#ifndef _FAAC_H_ |
| 23 |
#define _FAAC_H_ |
| 24 |
|
| 25 |
#ifdef __cplusplus |
| 26 |
extern "C" { |
| 27 |
#endif |
| 28 |
|
| 29 |
|
| 30 |
#if !defined(FAACAPI) && defined(__GNUC__) && (__GNUC__ >= 4) |
| 31 |
# if defined(_WIN32) |
| 32 |
# define FAACAPI __stdcall __declspec(dllexport) |
| 33 |
# else |
| 34 |
# define FAACAPI __attribute__((visibility("default"))) |
| 35 |
# endif |
| 36 |
#endif |
| 37 |
#ifndef FAACAPI |
| 38 |
# define FAACAPI |
| 39 |
#endif |
| 40 |
|
| 41 |
#pragma pack(push, 1) |
| 42 |
|
| 43 |
typedef struct { |
| 44 |
void *ptr; |
| 45 |
char *name; |
| 46 |
} |
| 47 |
psymodellist_t; |
| 48 |
|
| 49 |
#include <stdint.h> |
| 50 |
#include "faaccfg.h" |
| 51 |
|
| 52 |
|
| 53 |
typedef void *faacEncHandle; |
| 54 |
|
| 55 |
|
| 56 |
|
| 57 |
|
| 58 |
|
| 59 |
|
| 60 |
|
| 61 |
int FAACAPI faacEncGetVersion(char **faac_id_string, |
| 62 |
char **faac_copyright_string); |
| 63 |
|
| 64 |
|
| 65 |
faacEncConfigurationPtr FAACAPI |
| 66 |
faacEncGetCurrentConfiguration(faacEncHandle hEncoder); |
| 67 |
|
| 68 |
|
| 69 |
int FAACAPI faacEncSetConfiguration(faacEncHandle hEncoder, |
| 70 |
faacEncConfigurationPtr config); |
| 71 |
|
| 72 |
|
| 73 |
faacEncHandle FAACAPI faacEncOpen(unsigned long sampleRate, |
| 74 |
unsigned int numChannels, |
| 75 |
unsigned long *inputSamples, |
| 76 |
unsigned long *maxOutputBytes |
| 77 |
); |
| 78 |
|
| 79 |
int FAACAPI faacEncGetDecoderSpecificInfo(faacEncHandle hEncoder, unsigned char **ppBuffer, |
| 80 |
unsigned long *pSizeOfDecoderSpecificInfo); |
| 81 |
|
| 82 |
|
| 83 |
int FAACAPI faacEncEncode(faacEncHandle hEncoder, int32_t * inputBuffer, unsigned int samplesInput, |
| 84 |
unsigned char *outputBuffer, |
| 85 |
unsigned int bufferSize); |
| 86 |
|
| 87 |
|
| 88 |
int FAACAPI faacEncClose(faacEncHandle hEncoder); |
| 89 |
|
| 90 |
|
| 91 |
|
| 92 |
#pragma pack(pop) |
| 93 |
|
| 94 |
#ifdef __cplusplus |
| 95 |
} |
| 96 |
#endif |
| 97 |
|
| 98 |
#endif |