diff options
author | Andreas Eversberg <jolly@eversberg.eu> | 2016-06-20 19:37:56 +0200 |
---|---|---|
committer | Andreas Eversberg <jolly@eversberg.eu> | 2016-06-20 19:37:56 +0200 |
commit | 2ee51022f41d2877a18615cb67e49f9d9f626aaa (patch) | |
tree | 3a0c4e312a805c0695310959e91899c3e4571072 /src/common | |
parent | 86daa5a64a24312a0bd622d0c5415ef2b60c27bb (diff) |
Rename 'compander' to 'compandor'
Diffstat (limited to 'src/common')
-rw-r--r-- | src/common/Makefile.am | 2 | ||||
-rw-r--r-- | src/common/compandor.c (renamed from src/common/compander.c) | 12 | ||||
-rw-r--r-- | src/common/compandor.h (renamed from src/common/compander.h) | 10 |
3 files changed, 12 insertions, 12 deletions
diff --git a/src/common/Makefile.am b/src/common/Makefile.am index f15a9ad..ab53e20 100644 --- a/src/common/Makefile.am +++ b/src/common/Makefile.am @@ -19,7 +19,7 @@ libcommon_a_SOURCES = \ ../common/mncc_sock.c \ ../common/cause.c \ ../common/emphasis.c \ - ../common/compander.c \ + ../common/compandor.c \ ../common/sender.c \ ../common/display_wave.c \ ../common/main_common.c diff --git a/src/common/compander.c b/src/common/compandor.c index 4413bb5..9aacbf6 100644 --- a/src/common/compander.c +++ b/src/common/compandor.c @@ -1,4 +1,4 @@ -/* Compander to use various networks like C-Netz / NMT / AMPS +/* Compandor to use various networks like C-Netz / NMT / AMPS * * (C) 2016 by Andreas Eversberg <jolly@eversberg.eu> * All Rights Reserved @@ -21,7 +21,7 @@ #include <stdint.h> #include <string.h> #include <math.h> -#include "compander.h" +#include "compandor.h" //#define db2level(db) pow(10, (double)db / 20.0) @@ -37,12 +37,12 @@ static double sqrt_tab[10000]; /* - * Init compander according to ITU-T G.162 specification + * Init compandor according to ITU-T G.162 specification * * Hopefully this is correct * */ -void init_compander(compander_t *state, int samplerate, double attack_ms, double recovery_ms, int unaffected_level) +void init_compandor(compandor_t *state, int samplerate, double attack_ms, double recovery_ms, int unaffected_level) { int i; @@ -64,7 +64,7 @@ void init_compander(compander_t *state, int samplerate, double attack_ms, double sqrt_tab[i] = sqrt(i * 0.001); } -void compress_audio(compander_t *state, int16_t *samples, int num) +void compress_audio(compandor_t *state, int16_t *samples, int num) { int32_t sample; double value, peak, envelope, step_up, step_down, unaffected; @@ -114,7 +114,7 @@ void compress_audio(compander_t *state, int16_t *samples, int num) state->c.peak = peak; } -void expand_audio(compander_t *state, int16_t *samples, int num) +void expand_audio(compandor_t *state, int16_t *samples, int num) { int32_t sample; double value, peak, envelope, step_up, step_down, unaffected; diff --git a/src/common/compander.h b/src/common/compandor.h index 53d1967..df7dbc2 100644 --- a/src/common/compander.h +++ b/src/common/compandor.h @@ -1,4 +1,4 @@ -typedef struct compander { +typedef struct compandor { struct { double unaffected; double step_up; @@ -13,9 +13,9 @@ typedef struct compander { double peak; double envelope; } e; -} compander_t; +} compandor_t; -void init_compander(compander_t *state, int samplerate, double attack_ms, double recovery_ms, int unaffected_level); -void compress_audio(compander_t *state, int16_t *samples, int num); -void expand_audio(compander_t *state, int16_t *samples, int num); +void init_compandor(compandor_t *state, int samplerate, double attack_ms, double recovery_ms, int unaffected_level); +void compress_audio(compandor_t *state, int16_t *samples, int num); +void expand_audio(compandor_t *state, int16_t *samples, int num); |