diff options
author | Jeffrey Goode <jeffg7@gmail.com> | 2009-09-25 15:46:38 +0000 |
---|---|---|
committer | Jeffrey Goode <jeffg7@gmail.com> | 2009-09-25 15:46:38 +0000 |
commit | cf19ba5599b1cba212705ddb22166acf25eca83c (patch) | |
tree | 99e66ab4a5526ec7c36521c19179d96e42d7c3ae /apps/plugins | |
parent | b9a17dd0ceb1edc3e8d08522f82f9dfeabe53a53 (diff) | |
download | rockbox-cf19ba5599b1cba212705ddb22166acf25eca83c.tar.gz rockbox-cf19ba5599b1cba212705ddb22166acf25eca83c.zip |
Replace limiter with dynamic range compressor
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22832 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins')
-rw-r--r-- | apps/plugins/test_codec.c | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/apps/plugins/test_codec.c b/apps/plugins/test_codec.c index b77611689b..b41f053571 100644 --- a/apps/plugins/test_codec.c +++ b/apps/plugins/test_codec.c | |||
@@ -810,34 +810,10 @@ show_menu: | |||
810 | 810 | ||
811 | rb->closedir(dir); | 811 | rb->closedir(dir); |
812 | } | 812 | } |
813 | /* process last samples */ | ||
814 | if (use_dsp) | ||
815 | rb->dsp_flush_limiter_buffer(dspbuffer); | ||
816 | } else { | 813 | } else { |
817 | /* Just test the file */ | 814 | /* Just test the file */ |
818 | res = test_track(parameter); | 815 | res = test_track(parameter); |
819 | 816 | ||
820 | /* process last samples */ | ||
821 | if (use_dsp) | ||
822 | { | ||
823 | int channels = (wavinfo.stereomode == STEREO_MONO) ? 1 : 2; | ||
824 | int count = rb->dsp_flush_limiter_buffer(dspbuffer); | ||
825 | if (channels == 1) | ||
826 | { | ||
827 | unsigned char *s = dspbuffer, *d = dspbuffer; | ||
828 | int c = count; | ||
829 | while (c-- > 0) | ||
830 | { | ||
831 | *d++ = *s++; | ||
832 | *d++ = *s++; | ||
833 | s++; | ||
834 | s++; | ||
835 | } | ||
836 | } | ||
837 | if (wavinfo.fd >= 0) | ||
838 | rb->write(wavinfo.fd, dspbuffer, count * 2 * channels); | ||
839 | } | ||
840 | |||
841 | /* Close WAV file (if there was one) */ | 817 | /* Close WAV file (if there was one) */ |
842 | if (wavinfo.fd >= 0) { | 818 | if (wavinfo.fd >= 0) { |
843 | close_wav(); | 819 | close_wav(); |