projects
/
paraslash.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
remove duplicate prototypes for signal functions
[paraslash.git]
/
compress.c
diff --git
a/compress.c
b/compress.c
index b4e4c40a7a1663c95b38cdbada69715c519da5dc..936ddc3afe2cf5449d03109aac87925818a3739b 100644
(file)
--- a/
compress.c
+++ b/
compress.c
@@
-25,6
+25,7
@@
#include "para.h"
#include "compress_filter.cmdline.h"
#include "list.h"
#include "para.h"
#include "compress_filter.cmdline.h"
#include "list.h"
+#include "sched.h"
#include "filter.h"
#include "string.h"
#include "filter.h"
#include "string.h"
@@
-67,8
+68,8
@@
static ssize_t compress(char *inbuf, size_t inbuf_len, struct filter_node *fn)
>> gain_shift;
if (unlikely(adjusted_sample > 32767)) {
adjusted_sample = 32767;
>> gain_shift;
if (unlikely(adjusted_sample > 32767)) {
adjusted_sample = 32767;
- pcd->current_gain = (pcd->current_gain +
- (1 << pcd->conf->inertia_arg)) /
2
;
+ pcd->current_gain = (
3 *
pcd->current_gain +
+ (1 << pcd->conf->inertia_arg)) /
4
;
pcd->peak = 0;
} else
if (adjusted_sample > pcd->peak)
pcd->peak = 0;
} else
if (adjusted_sample > pcd->peak)
@@
-78,8
+79,8
@@
static ssize_t compress(char *inbuf, size_t inbuf_len, struct filter_node *fn)
>> gain_shift);
if (unlikely(adjusted_sample < -32768)) {
adjusted_sample = -32768;
>> gain_shift);
if (unlikely(adjusted_sample < -32768)) {
adjusted_sample = -32768;
- pcd->current_gain = (pcd->current_gain +
- (1 << pcd->conf->inertia_arg)) /
2
;
+ pcd->current_gain = (
3 *
pcd->current_gain +
+ (1 << pcd->conf->inertia_arg)) /
4
;
pcd->peak = 0;
} else
if (-adjusted_sample > pcd->peak)
pcd->peak = 0;
} else
if (-adjusted_sample > pcd->peak)