From 54f3eccad77103ff7441470cbfc5739180f3c1ba Mon Sep 17 00:00:00 2001 From: David CARLIER Date: Wed, 11 Oct 2017 02:35:02 +0100 Subject: [PATCH] linkage issue fixes due to inlined functions (#3815) --- plugins/LadspaEffect/swh/hermes_filter_1200.c | 6 +++--- plugins/LadspaEffect/swh/sifter_1210.c | 4 ++-- plugins/LadspaEffect/swh/util/waveguide_nl.h | 14 +++++++------- plugins/LadspaEffect/swh/vocoder_1337.c | 4 ++-- 4 files changed, 14 insertions(+), 14 deletions(-) diff --git a/plugins/LadspaEffect/swh/hermes_filter_1200.c b/plugins/LadspaEffect/swh/hermes_filter_1200.c index 5cac646ba..2f4386488 100644 --- a/plugins/LadspaEffect/swh/hermes_filter_1200.c +++ b/plugins/LadspaEffect/swh/hermes_filter_1200.c @@ -73,7 +73,7 @@ typedef struct { float *op; // pointer to output value } sv_filter; -inline float soft_clip(float sc_in) { +float soft_clip(float sc_in) { if ((sc_in < CLIP) && (sc_in > -CLIP)) { return sc_in; } else if (sc_in > 0.0f) { @@ -86,7 +86,7 @@ inline float soft_clip(float sc_in) { /* Store data in SVF struct, takes the sampling frequency, cutoff frequency and Q, and fills in the structure passed */ -inline void setup_svf(sv_filter *sv, float fs, float fc, float q, int t) { +void setup_svf(sv_filter *sv, float fs, float fc, float q, int t) { sv->f = 2.0f * sinf(M_PI * fc / (float)(fs * F_R)); sv->q = 2.0f * cosf(powf(q, 0.1f) * M_PI * 0.5f); sv->qnrm = sqrtf(sv->q*0.5f + 0.01f); @@ -111,7 +111,7 @@ inline void setup_svf(sv_filter *sv, float fs, float fc, float q, int t) { /* Change the frequency of a running SVF */ -inline void setup_f_svf(sv_filter *sv, const float fs, const float fc) { +void setup_f_svf(sv_filter *sv, const float fs, const float fc) { sv->f = 2.0f * sin(M_PI * fc / ((float)(fs * F_R))); } diff --git a/plugins/LadspaEffect/swh/sifter_1210.c b/plugins/LadspaEffect/swh/sifter_1210.c index 0e401e887..f7d8b557b 100644 --- a/plugins/LadspaEffect/swh/sifter_1210.c +++ b/plugins/LadspaEffect/swh/sifter_1210.c @@ -31,7 +31,7 @@ static void __attribute__((constructor)) swh_init(); // forward declaration #define MAX_BSIZE 1000 -inline int partition(LADSPA_Data array[], int left, int right); +int partition(LADSPA_Data array[], int left, int right); void q_sort(LADSPA_Data array[], int left, int right) { float pivot = partition(array, left, right); @@ -44,7 +44,7 @@ void q_sort(LADSPA_Data array[], int left, int right) { } } -inline int partition(LADSPA_Data array[], int left, int right) { +int partition(LADSPA_Data array[], int left, int right) { float pivot = array[left]; while (left < right) { diff --git a/plugins/LadspaEffect/swh/util/waveguide_nl.h b/plugins/LadspaEffect/swh/util/waveguide_nl.h index 398518eb0..e882e7771 100644 --- a/plugins/LadspaEffect/swh/util/waveguide_nl.h +++ b/plugins/LadspaEffect/swh/util/waveguide_nl.h @@ -35,7 +35,7 @@ waveguide_nl *waveguide_nl_new(int size, float fc, float da, float db) return wg; } -inline void waveguide_nl_reset(waveguide_nl *wg) +void waveguide_nl_reset(waveguide_nl *wg) { memset(wg->buffer[0], 0, wg->size * sizeof(float)); memset(wg->buffer[1], 0, wg->size * sizeof(float)); @@ -45,7 +45,7 @@ inline void waveguide_nl_reset(waveguide_nl *wg) wg->zm1[1] = 0.0f; } -inline void waveguide_nl_free(waveguide_nl *wg) +void waveguide_nl_free(waveguide_nl *wg) { if (!wg) { return; @@ -55,7 +55,7 @@ inline void waveguide_nl_free(waveguide_nl *wg) free(wg); } -inline void waveguide_nl_set_delay(waveguide_nl *wg, int delay) +void waveguide_nl_set_delay(waveguide_nl *wg, int delay) { if (delay > wg->size) { wg->delay = wg->size; @@ -66,18 +66,18 @@ inline void waveguide_nl_set_delay(waveguide_nl *wg, int delay) } } -inline void waveguide_nl_set_fc(waveguide_nl *wg, float fc) +void waveguide_nl_set_fc(waveguide_nl *wg, float fc) { wg->fc = fc; } -inline void waveguide_nl_set_ap(waveguide_nl *wg, float da, float db) +void waveguide_nl_set_ap(waveguide_nl *wg, float da, float db) { wg->a1a = (1.0f - da) / (1.0f + da); wg->a1b = (1.0f - db) / (1.0f + db); } -inline void waveguide_nl_process_lin(waveguide_nl *wg, float in0, float in1, float *out0, float *out1) +void waveguide_nl_process_lin(waveguide_nl *wg, float in0, float in1, float *out0, float *out1) { float tmp; @@ -103,7 +103,7 @@ inline void waveguide_nl_process_lin(waveguide_nl *wg, float in0, float in1, flo } } -inline void waveguide_nl_process(waveguide_nl *wg, float in0, float in1, float *out0, float *out1) +void waveguide_nl_process(waveguide_nl *wg, float in0, float in1, float *out0, float *out1) { float tmp; float a1; diff --git a/plugins/LadspaEffect/swh/vocoder_1337.c b/plugins/LadspaEffect/swh/vocoder_1337.c index d28975fe7..957a2f381 100644 --- a/plugins/LadspaEffect/swh/vocoder_1337.c +++ b/plugins/LadspaEffect/swh/vocoder_1337.c @@ -47,7 +47,7 @@ struct bandpasses LADSPA_Data y[MAX_BANDS]; }; -void inline doBandpasses(struct bandpasses *bands, LADSPA_Data sample, int num_bands); +void doBandpasses(struct bandpasses *bands, LADSPA_Data sample, int num_bands); struct bands_out{ LADSPA_Data decay[MAX_BANDS]; @@ -65,7 +65,7 @@ const LADSPA_Data decay_table[] = 1/250.0, 1/250.0, 1/250.0 }; -void inline doBandpasses(struct bandpasses *bands, LADSPA_Data sample, int num_bands) +void doBandpasses(struct bandpasses *bands, LADSPA_Data sample, int num_bands) { int i; for (i=0; i < num_bands; i++)