summaryrefslogtreecommitdiffstats
path: root/combiner/speex.pl
diff options
context:
space:
mode:
Diffstat (limited to 'combiner/speex.pl')
-rwxr-xr-xcombiner/speex.pl64
1 files changed, 64 insertions, 0 deletions
diff --git a/combiner/speex.pl b/combiner/speex.pl
new file mode 100755
index 0000000..90fba80
--- /dev/null
+++ b/combiner/speex.pl
@@ -0,0 +1,64 @@
+#! /usr/bin/perl -w
+
+use strict;
+use warnings;
+use Combiner;
+
+my $w32 = '/usr/i686-w64-mingw32/sys-root/mingw/bin/';
+my $w64 = '/usr/x86_64-w64-mingw32/sys-root/mingw/bin/';
+
+my ($cmd, $dir);
+
+my @combs = (
+ [
+ ["--narrowband", "--wideband", "--ultra-wideband"],
+ ], [
+ ["--quality 0", "--quality 5", "--quality 10", ""],
+ ["--vbr", ""],
+ ["--comp 0", "--comp 10", ""]
+ ]
+);
+
+my @inits = (\&nop, \&init_w64);
+my @callbacks = (
+ sub($$) {
+ my ($name, $opts) = @_;
+
+ print "speexenc $opts 1.wav linux/$name.spx\n";
+ },
+ sub($$) {
+ my ($name, $opts) = @_;
+
+ print "${w64}speexenc.exe $opts 1.wav win64/$name.spx\n";
+ }
+);
+
+my @inits_dec = (\&nop, \&init_w64, \&init_w64);
+my @callbacks_dec = (
+ sub($$) {
+ my ($name, $opts) = @_;
+
+ print "speexdec linux/$name.spx linux/$name.wav\n";
+ },
+ sub($$) {
+ my ($name, $opts) = @_;
+
+ print "${w64}speexdec.exe win64/$name.spx win64/$name.wav\n";
+ },
+ sub($$) {
+ my ($name, $opts) = @_;
+
+ print "${w64}speexdec.exe linux/$name.spx linux-win64/$name.wav\n";
+ }
+);
+
+
+print qq[#! /bin/sh -ex
+rm -rf linux win32 win64 linux-win32 linux-win64
+mkdir linux win64 linux-win64
+
+];
+
+combiners(\@inits, \@callbacks, \@combs);
+
+combiners(\@inits_dec, \@callbacks_dec, \@combs);