lame.h | lame.h | |||
---|---|---|---|---|
skipping to change at line 21 | skipping to change at line 21 | |||
* This program is distributed in the hope that it will be useful, | * This program is distributed in the hope that it will be useful, | |||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |||
* GNU General Public License for more details. | * GNU General Public License for more details. | |||
* | * | |||
* You should have received a copy of the GNU General Public License | * You should have received a copy of the GNU General Public License | |||
* along with this program; see the file COPYING. If not, write to | * along with this program; see the file COPYING. If not, write to | |||
* the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. | * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. | |||
*/ | */ | |||
/* $Id: lame.h,v 1.103 2001/11/30 18:05:38 markt Exp $ */ | /* $Id: lame.h,v 1.107 2002/04/10 12:55:47 bouvigne Exp $ */ | |||
#ifndef LAME_LAME_H | #ifndef LAME_LAME_H | |||
#define LAME_LAME_H | #define LAME_LAME_H | |||
#include <stdio.h> | #include <stdio.h> | |||
#include <stdarg.h> | #include <stdarg.h> | |||
#if defined(__cplusplus) | #if defined(__cplusplus) | |||
extern "C" { | extern "C" { | |||
#endif | #endif | |||
skipping to change at line 68 | skipping to change at line 68 | |||
} MPEG_mode; | } MPEG_mode; | |||
/* Padding types */ | /* Padding types */ | |||
typedef enum Padding_type_e { | typedef enum Padding_type_e { | |||
PAD_NO = 0, | PAD_NO = 0, | |||
PAD_ALL, | PAD_ALL, | |||
PAD_ADJUST, | PAD_ADJUST, | |||
PAD_MAX_INDICATOR /* Don't use this! It's used for sanity checks. */ | PAD_MAX_INDICATOR /* Don't use this! It's used for sanity checks. */ | |||
} Padding_type; | } Padding_type; | |||
/*presets*/ | ||||
typedef enum preset_mode_e { | ||||
/*values from 8 to 320 should be reserved for abr bitrates*/ | ||||
/*for abr I'd suggest to directly use the targeted bitrate as a value*/ | ||||
ABR_8 = 8, | ||||
ABR_320 = 320, | ||||
R3MIX = 1000, | ||||
STANDARD = 1001, | ||||
EXTREME = 1002, | ||||
INSANE = 1003, | ||||
STANDARD_FAST = 1004, | ||||
EXTREME_FAST = 1005 | ||||
} preset_mode; | ||||
/*asm optimizations*/ | ||||
typedef enum asm_optimizations_e { | ||||
MMX = 1, | ||||
AMD_3DNOW = 2, | ||||
SSE = 3 | ||||
} asm_optimizations; | ||||
struct lame_global_struct; | struct lame_global_struct; | |||
typedef struct lame_global_struct lame_global_flags; | typedef struct lame_global_struct lame_global_flags; | |||
typedef lame_global_flags *lame_t; | typedef lame_global_flags *lame_t; | |||
/*********************************************************************** | /*********************************************************************** | |||
* | * | |||
* The LAME API | * The LAME API | |||
* These functions should be called, in this order, for each | * These functions should be called, in this order, for each | |||
* MP3 file to be encoded | * MP3 file to be encoded | |||
* | * | |||
skipping to change at line 212 | skipping to change at line 233 | |||
void (*func)(const char *, va_list)); | void (*func)(const char *, va_list)); | |||
int CDECL lame_set_msgf (lame_global_flags *, | int CDECL lame_set_msgf (lame_global_flags *, | |||
void (*func)(const char *, va_list)); | void (*func)(const char *, va_list)); | |||
/* set one of brate compression ratio. default is compression ratio of 11. */ | /* set one of brate compression ratio. default is compression ratio of 11. */ | |||
int CDECL lame_set_brate(lame_global_flags *, int); | int CDECL lame_set_brate(lame_global_flags *, int); | |||
int CDECL lame_get_brate(const lame_global_flags *); | int CDECL lame_get_brate(const lame_global_flags *); | |||
int CDECL lame_set_compression_ratio(lame_global_flags *, float); | int CDECL lame_set_compression_ratio(lame_global_flags *, float); | |||
float CDECL lame_get_compression_ratio(const lame_global_flags *); | float CDECL lame_get_compression_ratio(const lame_global_flags *); | |||
int CDECL lame_set_preset( lame_global_flags* gfp, int ); | ||||
int CDECL lame_set_asm_optimizations( lame_global_flags* gfp, int, int ); | ||||
/******************************************************************** | /******************************************************************** | |||
* frame params | * frame params | |||
***********************************************************************/ | ***********************************************************************/ | |||
// mark as copyright. default=0 | // mark as copyright. default=0 | |||
int CDECL lame_set_copyright(lame_global_flags *, int); | int CDECL lame_set_copyright(lame_global_flags *, int); | |||
int CDECL lame_get_copyright(const lame_global_flags *); | int CDECL lame_get_copyright(const lame_global_flags *); | |||
// mark as original. default=1 | // mark as original. default=1 | |||
int CDECL lame_set_original(lame_global_flags *, int); | int CDECL lame_set_original(lame_global_flags *, int); | |||
int CDECL lame_get_original(const lame_global_flags *); | int CDECL lame_get_original(const lame_global_flags *); | |||
skipping to change at line 263 | skipping to change at line 287 | |||
int CDECL lame_get_experimentalY(const lame_global_flags *); | int CDECL lame_get_experimentalY(const lame_global_flags *); | |||
// another experimental option. for testing only | // another experimental option. for testing only | |||
int CDECL lame_set_experimentalZ(lame_global_flags *, int); | int CDECL lame_set_experimentalZ(lame_global_flags *, int); | |||
int CDECL lame_get_experimentalZ(const lame_global_flags *); | int CDECL lame_get_experimentalZ(const lame_global_flags *); | |||
// Naoki's psycho acoustic model. default=0 | // Naoki's psycho acoustic model. default=0 | |||
int CDECL lame_set_exp_nspsytune(lame_global_flags *, int); | int CDECL lame_set_exp_nspsytune(lame_global_flags *, int); | |||
int CDECL lame_get_exp_nspsytune(const lame_global_flags *); | int CDECL lame_get_exp_nspsytune(const lame_global_flags *); | |||
int lame_set_exp_nspsytune2_int( lame_global_flags*, int, int); | ||||
float lame_set_exp_nspsytune2_real( lame_global_flags*, int, float); | ||||
void * lame_set_exp_nspsytune2_pointer( lame_global_flags*, int, void *); | ||||
/******************************************************************** | /******************************************************************** | |||
* VBR control | * VBR control | |||
***********************************************************************/ | ***********************************************************************/ | |||
// Types of VBR. default = vbr_off = CBR | // Types of VBR. default = vbr_off = CBR | |||
int CDECL lame_set_VBR(lame_global_flags *, vbr_mode); | int CDECL lame_set_VBR(lame_global_flags *, vbr_mode); | |||
vbr_mode CDECL lame_get_VBR(const lame_global_flags *); | vbr_mode CDECL lame_get_VBR(const lame_global_flags *); | |||
// VBR quality level. 0=highest 9=lowest | // VBR quality level. 0=highest 9=lowest | |||
int CDECL lame_set_VBR_q(lame_global_flags *, int); | int CDECL lame_set_VBR_q(lame_global_flags *, int); | |||
int CDECL lame_get_VBR_q(const lame_global_flags *); | int CDECL lame_get_VBR_q(const lame_global_flags *); | |||
skipping to change at line 355 | skipping to change at line 383 | |||
// allow blocktypes to differ between channels? | // allow blocktypes to differ between channels? | |||
// default: 0 for jstereo, 1 for stereo | // default: 0 for jstereo, 1 for stereo | |||
int CDECL lame_set_allow_diff_short(lame_global_flags *, int); | int CDECL lame_set_allow_diff_short(lame_global_flags *, int); | |||
int CDECL lame_get_allow_diff_short(const lame_global_flags *); | int CDECL lame_get_allow_diff_short(const lame_global_flags *); | |||
// use temporal masking effect (default = 1) | // use temporal masking effect (default = 1) | |||
int CDECL lame_set_useTemporal(lame_global_flags *, int); | int CDECL lame_set_useTemporal(lame_global_flags *, int); | |||
int CDECL lame_get_useTemporal(const lame_global_flags *); | int CDECL lame_get_useTemporal(const lame_global_flags *); | |||
// use temporal masking effect (default = 1) | ||||
int CDECL lame_set_interChRatio(lame_global_flags *, float); | ||||
int CDECL lame_get_interChRatio(const lame_global_flags *); | ||||
// disable short blocks | // disable short blocks | |||
int CDECL lame_set_no_short_blocks(lame_global_flags *, int); | int CDECL lame_set_no_short_blocks(lame_global_flags *, int); | |||
int CDECL lame_get_no_short_blocks(const lame_global_flags *); | int CDECL lame_get_no_short_blocks(const lame_global_flags *); | |||
// force short blocks | // force short blocks | |||
int CDECL lame_set_force_short_blocks(lame_global_flags *, int); | int CDECL lame_set_force_short_blocks(lame_global_flags *, int); | |||
int CDECL lame_get_force_short_blocks(const lame_global_flags *); | int CDECL lame_get_force_short_blocks(const lame_global_flags *); | |||
/* Input PCM is emphased PCM (for instance from one of the rarely | /* Input PCM is emphased PCM (for instance from one of the rarely | |||
emphased CDs), it is STRONGLY not recommended to use this, because | emphased CDs), it is STRONGLY not recommended to use this, because | |||
End of changes. 5 change blocks. | ||||
1 lines changed or deleted | 33 lines changed or added | |||