2009-07-22 19:25:41 +02:00
|
|
|
/* Finite impulse response (FIR) resampler with adjustable FIR size */
|
|
|
|
|
|
|
|
/* Game_Music_Emu 0.5.2 */
|
|
|
|
#ifndef FIR_RESAMPLER_H
|
|
|
|
#define FIR_RESAMPLER_H
|
|
|
|
|
|
|
|
#define STEREO 2
|
|
|
|
#define MAX_RES 32
|
|
|
|
#define WIDTH 16
|
|
|
|
#define WRITE_OFFSET (WIDTH * STEREO) - STEREO
|
|
|
|
#define GAIN 1.0
|
|
|
|
|
2010-04-21 14:50:29 +02:00
|
|
|
typedef signed long int sample_t;
|
2009-07-22 19:25:41 +02:00
|
|
|
|
|
|
|
extern int Fir_Resampler_initialize( int new_size );
|
|
|
|
extern void Fir_Resampler_shutdown( void );
|
|
|
|
extern void Fir_Resampler_clear( void );
|
2010-02-28 20:55:43 +01:00
|
|
|
extern double Fir_Resampler_time_ratio( double new_factor, double rolloff );
|
2009-07-22 19:25:41 +02:00
|
|
|
extern double Fir_Resampler_ratio( void );
|
|
|
|
extern int Fir_Resampler_max_write( void );
|
|
|
|
extern sample_t* Fir_Resampler_buffer( void );
|
|
|
|
extern int Fir_Resampler_written( void );
|
|
|
|
extern int Fir_Resampler_avail( void );
|
|
|
|
extern void Fir_Resampler_write( long count );
|
2010-01-24 12:41:53 +01:00
|
|
|
extern int Fir_Resampler_read( sample_t* out, long count );
|
2010-01-13 23:08:35 +01:00
|
|
|
extern int Fir_Resampler_input_needed( long output_count );
|
2009-07-22 19:25:41 +02:00
|
|
|
extern int Fir_Resampler_skip_input( long count );
|
|
|
|
|
|
|
|
#endif
|