FreeCalypso > hg > vband-misc
comparison pcma2efr/comb-out.c @ 30:760bbae44c1f
pcma2efr: emit the set of computed frames
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Mon, 13 May 2024 05:40:56 +0000 |
parents | pcmu2efr/comb-out.c@1f58ba0d79a4 |
children |
comparison
equal
deleted
inserted
replaced
29:fc4544e3687b | 30:760bbae44c1f |
---|---|
1 /* | |
2 * This program computes 160 possible EFR encoder outputs using standard EFR, | |
3 * then 160 possible outputs in AMR-EFR, then writes out all 320 frames | |
4 * to a gsmx output file. | |
5 */ | |
6 | |
7 #include <stdio.h> | |
8 #include <stdint.h> | |
9 #include <stdlib.h> | |
10 #include <string.h> | |
11 #include <strings.h> | |
12 | |
13 extern uint8_t standard_efr[160][31]; | |
14 extern uint8_t amr_efr[160][31]; | |
15 | |
16 main(argc, argv) | |
17 char **argv; | |
18 { | |
19 FILE *outf; | |
20 | |
21 if (argc != 2) { | |
22 fprintf(stderr, "usage: %s gsmx-out-file\n", argv[0]); | |
23 exit(1); | |
24 } | |
25 generate_linear_inputs(); | |
26 generate_std_efr(); | |
27 generate_amr_efr(); | |
28 outf = fopen(argv[1], "w"); | |
29 if (!outf) { | |
30 perror(argv[1]); | |
31 exit(1); | |
32 } | |
33 fwrite(standard_efr, 31, 160, outf); | |
34 fwrite(amr_efr, 31, 160, outf); | |
35 fclose(outf); | |
36 exit(0); | |
37 } |