History

Merge tests/calc_snr.h into tests/util.h and remove old file.

Erik de Castro Lopo committed 20 years ago

Commit c8a94e01 parent 5caea029 files · +8 −39Browse files

Unified · Split

9 files
  1. tests/Makefile.am +2 −2
  2. tests/benchmark.c +0 −1
  3. tests/calc_snr.c +0 −1
  4. tests/calc_snr.h +0 −27
  5. tests/multi_channel_test.c +2 −3
  6. tests/snr_bw_test.c +2 −3
  7. tests/src-evaluate.c +0 −1
  8. tests/util.h +2 −0
  9. tests/varispeed_test.c +0 −1
tests/Makefile.am+2−2
@@ -4,7 +4,7 @@ noinst_PROGRAMS = misc_test termination_test simple_test callback_test \ · 3 unmodified lines
44
55 SAMPLRATEDIR =../src
66 INCLUDES = -I$(srcdir)/$(SAMPLRATEDIR)
7−noinst_HEADERS = calc_snr.h util.h
7+noinst_HEADERS = util.h
88
99 #===============================================================================
1010
@@ -35,7 +35,7 @@ callback_test_LDADD = $(SAMPLRATEDIR)/libsamplerate.la · 24 unmodified lines
3535 float_short_test_SOURCES = float_short_test.c util.c util.h
3636 float_short_test_LDADD = $(SAMPLRATEDIR)/libsamplerate.la
3737
38−varispeed_test_SOURCES = varispeed_test.c util.c util.h calc_snr.c calc_snr.h
38+varispeed_test_SOURCES = varispeed_test.c util.c util.h calc_snr.c
3939 varispeed_test_LDADD = $(SAMPLRATEDIR)/libsamplerate.la $(FFTW3_LIBS)
4040
4141 # This program is for evaluating other sample rate converters.
tests/benchmark.c+0−1
@@ -7,7 +7,6 @@ · 6 unmodified lines
77 #include <samplerate.h>
88
99 #include "util.h"
10−#include "calc_snr.h"
1110
1211 #define BUFFER_LEN (1<<23)
1312 #define SNR_LEN (1<<16)
tests/calc_snr.c+0−1
@@ -18,7 +18,6 @@ · 17 unmodified lines
1818
1919 #include "config.h"
2020
21−#include "calc_snr.h"
2221 #include "util.h"
2322
2423 #if (HAVE_FFTW3 == 1)
tests/calc_snr.h+0−27
@@ -1,27 +0,0 @@
1−/*
2−** Copyright (C) 2002-2004 Erik de Castro Lopo <erikd@mega-nerd.com>
3−**
4−** This program is free software; you can redistribute it and/or modify
5−** it under the terms of the GNU General Public License as published by
6−** the Free Software Foundation; either version 2 of the License, or
7−** (at your option) any later version.
8−**
9−** This program is distributed in the hope that it will be useful,
10−** but WITHOUT ANY WARRANTY; without even the implied warranty of
11−** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12−** GNU General Public License for more details.
13−**
14−** You should have received a copy of the GNU General Public License
15−** along with this program; if not, write to the Free Software
16−** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
17−*/
18−
19−double calculate_snr (float *data, int len, int expected_peaks) ;
20−/*
21−** Do not edit or modify anything in this comment block.
22−** The arch-tag line is a file identity tag for the GNU Arch
23−** revision control system.
24−**
25−** arch-tag: b35c91c0-a2a7-4628-8c4e-59b582da2f42
26−*/
27−
tests/multi_channel_test.c+2−3
@@ -16,6 +16,8 @@ · 15 unmodified lines
1616 ** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
1717 */
1818
19+#include "config.h"
20+
1921 #include <stdio.h>
2022 #include <stdlib.h>
2123 #include <string.h>
@@ -24,9 +26,6 @@ · 2 unmodified lines
2426 #include <samplerate.h>
2527
2628 #include "util.h"
27−#include "calc_snr.h"
28−#include "config.h"
29−
3029 #define BUFFER_LEN (1<<15)
3130 #define BLOCK_LEN (12)
3231
tests/snr_bw_test.c+2−3
@@ -16,20 +16,19 @@ · 15 unmodified lines
1616 ** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
1717 */
1818
19+#include "config.h"
20+
1921 #include <stdio.h>
2022 #include <stdlib.h>
2123 #include <string.h>
2224 #include <math.h>
2325 #include <time.h>
2426
25−#include "config.h"
26−
2727 #if (HAVE_FFTW3)
2828
2929 #include <samplerate.h>
3030
3131 #include "util.h"
32−#include "calc_snr.h"
3332
3433 #define BUFFER_LEN 50000
3534 #define MAX_FREQS 4
tests/src-evaluate.c+0−1
@@ -33,7 +33,6 @@ · 32 unmodified lines
3333 #include <math.h>
3434 #include <sys/utsname.h>
3535
36−#include "calc_snr.h"
3736 #include "util.h"
3837
3938 #define MAX_FREQS 4
tests/util.h+2−0
@@ -33,6 +33,8 @@ void deinterleave_data (const float *in, float *out, int frames, int channels) ; · 32 unmodified lines
3333
3434 void reverse_data (float *data, int datalen) ;
3535
36+double calculate_snr (float *data, int len, int expected_peaks) ;
37+
3638 /*
3739 ** Do not edit or modify anything in this comment block.
3840 ** The arch-tag line is a file identity tag for the GNU Arch
tests/varispeed_test.c+0−1
@@ -24,7 +24,6 @@ · 23 unmodified lines
2424 #include <samplerate.h>
2525
2626 #include "util.h"
27−#include "calc_snr.h"
2827
2928 #define BUFFER_LEN (1 << 16)
3029

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t