Add RARCH_INTERNAL ifdefs (for consoles/handhelds later on)

This commit is contained in:
twinaphex 2014-04-28 05:59:24 +02:00
parent 9d927ef827
commit 79f16c267e
8 changed files with 109 additions and 0 deletions

View File

@ -51,6 +51,13 @@ struct echo_filter_data
float input_rate;
};
#ifdef RARCH_INTERNAL
#define rarch_dsp_init echo_sse_dsp_init
#define rarch_dsp_process echo_sse_dsp_process
#define rarch_dsp_free echo_sse_dsp_free
#define rarch_dsp_config echo_sse_dsp_config
#endif
void echo_init(void *data)
{
unsigned i, j;
@ -203,3 +210,10 @@ RARCH_API_EXPORT const rarch_dsp_plugin_t* RARCH_API_CALLTYPE
{
return &dsp_plug;
}
#ifdef RARCH_INTERNAL
#undef rarch_dsp_init
#undef rarch_dsp_process
#undef rarch_dsp_free
#undef rarch_dsp_config
#endif

View File

@ -35,6 +35,13 @@
#define ECHO_MS 150
#define AMP 0.0
#ifdef RARCH_INTERNAL
#define rarch_dsp_init echo_sse_dsp_init
#define rarch_dsp_process echo_sse_dsp_process
#define rarch_dsp_free echo_sse_dsp_free
#define rarch_dsp_config echo_sse_dsp_config
#endif
struct EchoFilter
{
float echo_buffer[4][0x10000] ALIGNED;
@ -195,3 +202,9 @@ RARCH_API_EXPORT const rarch_dsp_plugin_t* RARCH_API_CALLTYPE
return &dsp_plug;
}
#ifdef RARCH_INTERNAL
#undef rarch_dsp_init
#undef rarch_dsp_process
#undef rarch_dsp_free
#undef rarch_dsp_config
#endif

View File

@ -38,6 +38,13 @@
#define EQ_FILT_SIZE (EQ_COEFF_SIZE * 2)
#endif
#ifdef RARCH_INTERNAL
#define rarch_dsp_init eq_dsp_init
#define rarch_dsp_process eq_dsp_process
#define rarch_dsp_free eq_dsp_free
#define rarch_dsp_config eq_dsp_config
#endif
typedef struct dsp_eq_state dsp_eq_state_t;
static complex float phase_lut[2 * EQ_FILT_SIZE + 1];
@ -411,3 +418,9 @@ RARCH_API_EXPORT const rarch_dsp_plugin_t* RARCH_API_CALLTYPE rarch_dsp_plugin_i
return &dsp_plug;
}
#ifdef RARCH_INTERNAL
#undef rarch_dsp_init
#undef rarch_dsp_process
#undef rarch_dsp_free
#undef rarch_dsp_config
#endif

View File

@ -33,6 +33,13 @@
#define sqr(a) ((a) * (a))
#ifdef RARCH_INTERNAL
#define rarch_dsp_init iir_dsp_init
#define rarch_dsp_process iir_dsp_process
#define rarch_dsp_free iir_dsp_free
#define rarch_dsp_config iir_dsp_config
#endif
struct iir_filter
{
#ifdef __SSE2__
@ -379,3 +386,10 @@ RARCH_API_EXPORT const rarch_dsp_plugin_t* RARCH_API_CALLTYPE rarch_dsp_plugin_i
{
return &dsp_plug;
}
#ifdef RARCH_INTERNAL
#undef rarch_dsp_init
#undef rarch_dsp_process
#undef rarch_dsp_free
#undef rarch_dsp_config
#endif

View File

@ -29,6 +29,13 @@
#define PHASERLFOSHAPE 4.0
#define PHASER_LFOSKIPSAMPLES 20
#ifdef RARCH_INTERNAL
#define rarch_dsp_init phaser_dsp_init
#define rarch_dsp_process phaser_dsp_process
#define rarch_dsp_free phaser_dsp_free
#define rarch_dsp_config phaser_dsp_config
#endif
struct phaser_filter
{
float freq;
@ -181,3 +188,10 @@ RARCH_API_EXPORT const rarch_dsp_plugin_t* RARCH_API_CALLTYPE rarch_dsp_plugin_i
{
return &dsp_plug;
}
#ifdef RARCH_INTERNAL
#undef rarch_dsp_init
#undef rarch_dsp_process
#undef rarch_dsp_free
#undef rarch_dsp_config
#endif

View File

@ -51,6 +51,13 @@
#define ALLPASSTUNINGL3 341
#define ALLPASSTUNINGL4 225
#ifdef RARCH_INTERNAL
#define rarch_dsp_init reverb_dsp_init
#define rarch_dsp_process reverb_dsp_process
#define rarch_dsp_free reverb_dsp_free
#define rarch_dsp_config reverb_dsp_config
#endif
struct comb
{
float feedback;
@ -385,3 +392,10 @@ RARCH_API_EXPORT const rarch_dsp_plugin_t* RARCH_API_CALLTYPE rarch_dsp_plugin_i
{
return &dsp_plug;
}
#ifdef RARCH_INTERNAL
#undef rarch_dsp_init
#undef rarch_dsp_process
#undef rarch_dsp_free
#undef rarch_dsp_config
#endif

View File

@ -20,6 +20,13 @@
#include <stdlib.h>
#include <math.h>
#ifdef RARCH_INTERNAL
#define rarch_dsp_init volume_dsp_init
#define rarch_dsp_process volume_dsp_process
#define rarch_dsp_free volume_dsp_free
#define rarch_dsp_config volume_dsp_config
#endif
struct volume_filter_data
{
#ifdef __GNUC__
@ -119,3 +126,9 @@ RARCH_API_EXPORT const rarch_dsp_plugin_t* RARCH_API_CALLTYPE rarch_dsp_plugin_i
return &dsp_plug;
}
#ifdef RARCH_INTERNAL
#undef rarch_dsp_init
#undef rarch_dsp_process
#undef rarch_dsp_free
#undef rarch_dsp_config
#endif

View File

@ -30,6 +30,13 @@
#define LFOSKIPSAMPLES 30
#endif
#ifdef RARCH_INTERNAL
#define rarch_dsp_init wah_dsp_init
#define rarch_dsp_process wah_dsp_process
#define rarch_dsp_free wah_dsp_free
#define rarch_dsp_config wah_dsp_config
#endif
struct wahwah_filter
{
float phase;
@ -174,3 +181,10 @@ RARCH_API_EXPORT const rarch_dsp_plugin_t* RARCH_API_CALLTYPE rarch_dsp_plugin_i
{
return &dsp_plug;
}
#ifdef RARCH_INTERNAL
#undef rarch_dsp_init
#undef rarch_dsp_process
#undef rarch_dsp_free
#undef rarch_dsp_config
#endif