-
Notifications
You must be signed in to change notification settings - Fork 1
/
sp_dec.h
85 lines (75 loc) · 1.51 KB
/
sp_dec.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
/*
* ===================================================================
* TS 26.104
* REL-5 V5.4.0 2004-03
* REL-6 V6.1.0 2004-03
* REL-15 V15.1.0 2018-07
* 3GPP AMR Floating-point Speech Codec
* ===================================================================
*
*/
/*
* sp_enc.h
*
*
* Project:
* AMR Floating-Point Codec
*
* Contains:
* Defines interface to AMR encoder
*
*/
#ifndef _SP_DEC_H_
#define _SP_DEC_H_
#include "sp_enc.h"
/*
* definition of enumerated types
*/
/*
* definition of modes for decoder
*/
// enum Mode { MR475 = 0,
// MR515,
// MR59,
// MR67,
// MR74,
// MR795,
// MR102,
// MR122,
// MRDTX,
// N_MODES /* number of (SPC) modes */
// };
/* Declaration recieved frame types */
enum RXFrameType
{
RX_SPEECH_GOOD = 0,
RX_SPEECH_DEGRADED,
RX_ONSET,
RX_SPEECH_BAD,
RX_SID_FIRST,
RX_SID_UPDATE,
RX_SID_BAD,
RX_NO_DATA,
RX_N_FRAMETYPES /* number of frame types */
};
/*
* Function prototypes
*/
/*
* initialize one instance of the speech decoder
*/
void *Speech_Decode_Frame_init(void);
/*
* free status struct
*/
void Speech_Decode_Frame_exit(void **st);
/*
* Decodes one frame from encoded parameters
*/
void Speech_Decode_Frame(void *st, enum Mode mode, short *serial,
enum RXFrameType frame_type, short *synth);
/*
* reset speech decoder
*/
int Speech_Decode_Frame_reset(void **st);
#endif