Updated SWH plugins and added missing hermes_filter plugin

There were minor updates in SWH Git repository. Incorporated bug fixes
and added missing hermes_filter plugin.
This commit is contained in:
Tobias Doerffel
2012-01-13 22:25:44 +01:00
parent 0bcd267063
commit cacc0d6c3e
7 changed files with 2046 additions and 9 deletions

View File

@@ -51,6 +51,10 @@ ADD_LIBRARY(gverb STATIC gverb/gverb.c gverb/gverbdsp.c)
SET_TARGET_PROPERTIES(gverb PROPERTIES COMPILE_FLAGS "-fPIC")
TARGET_LINK_LIBRARIES(gverb_1216 gverb)
ADD_LIBRARY(blo STATIC util/blo.c)
SET_TARGET_PROPERTIES(blo PROPERTIES COMPILE_FLAGS "-fPIC")
TARGET_LINK_LIBRARIES(hermes_filter_1200 blo)
ADD_LIBRARY(rms STATIC util/rms.c)
ADD_LIBRARY(db STATIC util/db.c)
SET_TARGET_PROPERTIES(rms PROPERTIES COMPILE_FLAGS "-fPIC")

View File

@@ -0,0 +1,16 @@
Copyright 1992, 1993, 1994 by Jutta Degener and Carsten Bormann,
Technische Universitaet Berlin
Any use of this software is permitted provided that this notice is not
removed and that neither the authors nor the Technische Universitaet Berlin
are deemed to have made any representations as to the suitability of this
software for any purpose nor are held responsible for any defects of
this software. THERE IS ABSOLUTELY NO WARRANTY FOR THIS SOFTWARE.
As a matter of courtesy, the authors request to be informed about uses
this software has found, about bugs in this software, and about any
improvements that may be of general interest.
Berlin, 28.11.1994
Jutta Degener
Carsten Bormann

File diff suppressed because it is too large Load Diff

View File

@@ -457,7 +457,8 @@ static void runMbeq(LADSPA_Handle instance, unsigned long sample_count) {
#endif
// Multiply the bins magnitudes by the coeficients
for (i = 0; i < FFT_LENGTH/2; i++) {
comp[0] *= coefs[0];
for (i = 1; i < FFT_LENGTH/2; i++) {
comp[i] *= coefs[i];
comp[FFT_LENGTH-i] *= coefs[i];
}
@@ -621,7 +622,8 @@ static void runAddingMbeq(LADSPA_Handle instance, unsigned long sample_count) {
#endif
// Multiply the bins magnitudes by the coeficients
for (i = 0; i < FFT_LENGTH/2; i++) {
comp[0] *= coefs[0];
for (i = 1; i < FFT_LENGTH/2; i++) {
comp[i] *= coefs[i];
comp[FFT_LENGTH-i] *= coefs[i];
}

View File

@@ -58,6 +58,7 @@ blo_h_tables *blo_h_tables_new(int table_size)
snprintf(shm_path, 128, "/blo-1-%dx%dx%d.tbl", BLO_N_WAVES,
BLO_N_HARMONICS, table_size + BLO_TABLE_WR);
#ifndef WIN32
if ((shm_fd = shm_open(shm_path, O_RDONLY, 0)) > 0) {
/* There is an existing SHM segment that matches what we want */
@@ -127,6 +128,7 @@ blo_h_tables *blo_h_tables_new(int table_size)
MAP_SHARED, shm_fd, 0);
close(shm_fd);
}
#endif
/* Fallback case, can't map a SHM segment, just malloc it and suffer */
if (!all_tables) {
@@ -226,7 +228,9 @@ blo_h_tables *blo_h_tables_new(int table_size)
}
}
#ifndef WIN32
msync(all_tables, all_tables_size, MS_ASYNC);
#endif
return this;
}
@@ -234,7 +238,9 @@ blo_h_tables *blo_h_tables_new(int table_size)
void blo_h_tables_free(blo_h_tables *tables)
{
if (tables->store_type == BLO_MMAP) {
#ifndef WIN32
munmap(tables->alloc_space, tables->alloc_size);
#endif
} else {
free(tables->alloc_space);
}

View File

@@ -86,9 +86,9 @@ void combine_iir_stages(int mode, iir_stage_t* gt, iir_stage_t *first, iir_stage
void free_iir_stage(iir_stage_t *gt){
int i;
for(i=0;i<gt->availst;i++)
free(gt->coeff[i]);
free(gt->coeff);
free(gt);
if (gt->coeff[i]) free(gt->coeff[i]);
if (gt->coeff) free(gt->coeff);
if (gt) free(gt);
}
/* center: frequency already normalized between 0 and 0.5 of sampling

View File

@@ -1,7 +1,7 @@
#ifndef IIR_H
#define IIR_H
#include "../ladspa-util.h"
#include <ladspa-util.h>
/* header file for IIR framework */
@@ -64,10 +64,10 @@ static inline iirf_t* init_iirf_t(iir_stage_t* gt) {
static inline void free_iirf_t(iirf_t* iirf, iir_stage_t* gt) {
int i;
for(i=0;i<gt->availst;i++){
free(iirf[i].iring);
free(iirf[i].oring);
if (iirf[i].iring) free(iirf[i].iring);
if (iirf[i].oring) free(iirf[i].oring);
}
free(iirf);
if (iirf) free(iirf);
};
static inline void reset_iirf_t(iirf_t* iirf, iir_stage_t* gt, int n) {