20 #ifndef __EXPORTMP3_H__ 21 #define __EXPORTMP3_H__ 24 #include "lame/lame.h" 40 #define CHANNEL_JOINT 0 41 #define CHANNEL_STEREO 1 54 #define ROUTINE_FAST 0 55 #define ROUTINE_STANDARD 1 57 #define PRESET_INSANE 0 58 #define PRESET_EXTREME 1 59 #define PRESET_STANDARD 2 60 #define PRESET_MEDIUM 3 72 lame_global_flags* gf,
73 const float buffer_l [],
74 const float buffer_r [],
76 unsigned char * mp3buf,
77 const int mp3buf_size );
80 lame_global_flags *gf,
81 unsigned char* mp3buf,
103 #if defined(Q_OS_WIN) 107 typedef unsigned long beWriteInfoTag_t(lame_global_flags *,
char *);
115 BYTE byDLLMajorVersion;
116 BYTE byDLLMinorVersion;
137 BYTE btReserved[125];
139 typedef void beVersion_t(be_version *);
184 int encodeBuffer(
float inbufferL[],
float inbufferR[],
unsigned char outbuffer[]);
185 int encodeRemainder(
float inbufferL[],
float inbufferR[],
int nSamples,
186 unsigned char outbuffer[]);
190 unsigned char outbuffer[]);
202 #if defined(Q_OS_WIN) 203 QString mBladeVersion;
237 #if defined(Q_OS_WIN) 238 beWriteInfoTag_t *beWriteInfoTag;
239 beVersion_t *beVersion;
248 mSamplesPerChunk * (320 / 8) / 8 + 4 * 1152 * (320 / 8) / 8 + 512;
257 #endif //__EXPORTMP3_H__ MP3Exporter()
Definition: exportmp3.cpp:34
lame_encode_buffer_float_t * lame_encode_buffer_float
Definition: exportmp3.h:216
int encodeBufferMono(float inbuffer[], unsigned char outbuffer[])
Definition: exportmp3.cpp:470
int lame_encode_flush_t(lame_global_flags *gf, unsigned char *mp3buf, int size)
Definition: exportmp3.h:79
bool mEncoding
Definition: exportmp3.h:206
lame_set_VBR_t * lame_set_VBR
Definition: exportmp3.h:226
lame_set_preset_t * lame_set_preset
Definition: exportmp3.h:230
lame_close_t * lame_close
Definition: exportmp3.h:218
int encodeRemainder(float inbufferL[], float inbufferR[], int nSamples, unsigned char outbuffer[])
Definition: exportmp3.cpp:454
int lame_set_error_protection_t(lame_global_flags *, int)
Definition: exportmp3.h:96
bool findLibrary()
Definition: exportmp3.cpp:59
void lame_mp3_tags_fid_t(lame_global_flags *, FILE *)
Definition: exportmp3.h:101
void setChannel(int mode)
Definition: exportmp3.cpp:178
int getOutBufferSize()
Definition: exportmp3.cpp:417
virtual ~MP3Exporter()
Definition: exportmp3.cpp:50
void bufferPreamp(float buffer[], int nSamples)
Definition: exportmp3.cpp:429
int lame_set_mode_t(lame_global_flags *, MPEG_mode)
Definition: exportmp3.h:94
lame_init_t * lame_init
Definition: exportmp3.h:214
void setQuality(int q, int r)
Definition: exportmp3.cpp:172
QString getLibraryName()
Definition: exportmp3.cpp:596
int lame_set_VBR_min_bitrate_kbps_t(lame_global_flags *, int)
Definition: exportmp3.h:93
size_t mInfoTagLen
Definition: exportmp3.h:252
bool mLibraryLoaded
Definition: exportmp3.h:200
int lame_set_quality_t(lame_global_flags *, int)
Definition: exportmp3.h:89
lame_global_flags * lame_init_t(void)
Definition: exportmp3.h:67
lame_set_padding_type_t * lame_set_padding_type
Definition: exportmp3.h:233
int lame_set_brate_t(lame_global_flags *, int)
Definition: exportmp3.h:90
int lame_encode_buffer_float_t(lame_global_flags *gf, const float buffer_l [], const float buffer_r [], const int nsamples, unsigned char *mp3buf, const int mp3buf_size)
Definition: exportmp3.h:71
lame_set_VBR_min_bitrate_kbps_t * lame_set_VBR_min_bitrate_kbps
Definition: exportmp3.h:228
QLibrary * lame_lib
Definition: exportmp3.h:199
AskUser
Definition: exportmp3.h:149
lame_set_num_channels_t * lame_set_num_channels
Definition: exportmp3.h:223
lame_init_params_t * lame_init_params
Definition: exportmp3.h:215
lame_encode_flush_t * lame_encode_flush
Definition: exportmp3.h:217
lame_set_bWriteVbrTag_t * lame_set_bWriteVbrTag
Definition: exportmp3.h:234
int lame_set_num_channels_t(lame_global_flags *, int)
Definition: exportmp3.h:88
lame_mp3_tags_fid_t * lame_mp3_tags_fid
Definition: exportmp3.h:236
lame_get_lametag_frame_t * lame_get_lametag_frame
Definition: exportmp3.h:235
get_lame_version_t * get_lame_version
Definition: exportmp3.h:219
int lame_set_preset_t(lame_global_flags *, int)
Definition: exportmp3.h:95
int mBitrate
Definition: exportmp3.h:208
QString getLibraryVersion()
Definition: exportmp3.cpp:316
int lame_init_params_t(lame_global_flags *)
Definition: exportmp3.h:68
int lame_set_out_samplerate_t(lame_global_flags *, int)
Definition: exportmp3.h:87
lame_set_disable_reservoir_t * lame_set_disable_reservoir
Definition: exportmp3.h:232
Definition: aeolus.cpp:26
void setBitrate(int rate)
Definition: exportmp3.cpp:167
lame_set_error_protection_t * lame_set_error_protection
Definition: exportmp3.h:231
int mRoutine
Definition: exportmp3.h:210
void setMode(int mode)
Definition: exportmp3.cpp:162
QString getLibraryTypeString()
Definition: exportmp3.cpp:601
int finishStream(unsigned char outbuffer[])
Definition: exportmp3.cpp:499
bool loadLibrary(AskUser askuser)
Definition: exportmp3.cpp:104
int mQuality
Definition: exportmp3.h:209
int mChannel
Definition: exportmp3.h:211
lame_set_VBR_q_t * lame_set_VBR_q
Definition: exportmp3.h:227
int lame_set_bWriteVbrTag_t(lame_global_flags *, int)
Definition: exportmp3.h:99
Definition: exportmp3.h:146
int lame_set_disable_reservoir_t(lame_global_flags *, int)
Definition: exportmp3.h:97
size_t lame_get_lametag_frame_t(const lame_global_flags *, unsigned char *buffer, size_t size)
Definition: exportmp3.h:100
static const int mSamplesPerChunk
Definition: exportmp3.h:244
int initializeStream(int channels, int sampleRate)
Definition: exportmp3.cpp:327
int lame_set_VBR_q_t(lame_global_flags *, int)
Definition: exportmp3.h:92
bool validLibraryLoaded()
Definition: exportmp3.cpp:157
lame_set_quality_t * lame_set_quality
Definition: exportmp3.h:224
int lame_set_in_samplerate_t(lame_global_flags *, int)
Definition: exportmp3.h:86
lame_global_flags * mGF
Definition: exportmp3.h:242
int lame_set_VBR_t(lame_global_flags *, vbr_mode)
Definition: exportmp3.h:91
lame_set_in_samplerate_t * lame_set_in_samplerate
Definition: exportmp3.h:221
lame_set_out_samplerate_t * lame_set_out_samplerate
Definition: exportmp3.h:222
int encodeRemainderMono(float inbuffer[], int nSamples, unsigned char outbuffer[])
Definition: exportmp3.cpp:484
int lame_set_padding_type_t(lame_global_flags *, Padding_type)
Definition: exportmp3.h:98
int lame_close_t(lame_global_flags *)
Definition: exportmp3.h:84
void freeLibrary()
Definition: exportmp3.cpp:301
int mMode
Definition: exportmp3.h:207
QString mLibPath
Definition: exportmp3.h:198
const char * get_lame_version_t(void)
Definition: exportmp3.h:69
lame_set_mode_t * lame_set_mode
Definition: exportmp3.h:229
bool initLibrary(QString libpath)
Definition: exportmp3.cpp:187
QString getLibraryPath()
Q_OS_MAC.
Definition: exportmp3.cpp:591
static const int mOutBufferSize
Definition: exportmp3.h:247
unsigned char mInfoTagBuf[2880]
Definition: exportmp3.h:251
void cancelEncoding()
Definition: exportmp3.cpp:516
int encodeBuffer(float inbufferL[], float inbufferR[], unsigned char outbuffer[])
Definition: exportmp3.cpp:439
lame_set_brate_t * lame_set_brate
Definition: exportmp3.h:225