1 // Those select the specific syn123 functions, without
2 // this, the native wrapper is used, hopefully matching off_t.
3 //#define _FILE_OFFSET_BITS 64
4 //#define _FILE_OFFSET_BITS 32
5 #include <syn123.h>
6
7 #include <stdio.h>
8
9 const long arate = 8000;
10 const long brate = 48000;
11 const off_t ins = 12637;
12 const off_t outs = 75822;
13
main()14 int main()
15 {
16 off_t outs2 = syn123_resample_total(arate,brate,ins);
17 off_t ins2 = syn123_resample_intotal(arate,brate,outs);
18 int err = 0;
19 if(outs2 != outs && ++err)
20 fprintf(stderr, "total mismatch: %ld != %ld\n"
21 , (long)outs2, (long)outs );
22 if(ins2 != ins && ++err)
23 fprintf(stderr, "intotal mismatch: %ld != %ld\n"
24 , (long)ins2, (long)ins );
25 printf("%s\n", err ? "FAIL" : "PASS");
26 return err;
27 }
28