Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
2 | mjames | 1 | #include "ref.h" |
2 | |||
3 | void ref_sub_f32( |
||
4 | float32_t * pSrcA, |
||
5 | float32_t * pSrcB, |
||
6 | float32_t * pDst, |
||
7 | uint32_t blockSize) |
||
8 | { |
||
9 | uint32_t i; |
||
10 | |||
11 | for(i=0;i<blockSize;i++) |
||
12 | { |
||
13 | pDst[i] = pSrcA[i] - pSrcB[i]; |
||
14 | } |
||
15 | } |
||
16 | |||
17 | void ref_sub_q31( |
||
18 | q31_t * pSrcA, |
||
19 | q31_t * pSrcB, |
||
20 | q31_t * pDst, |
||
21 | uint32_t blockSize) |
||
22 | { |
||
23 | uint32_t i; |
||
24 | |||
25 | for(i=0;i<blockSize;i++) |
||
26 | { |
||
27 | pDst[i] = ref_sat_q31( (q63_t)pSrcA[i] - pSrcB[i] ); |
||
28 | } |
||
29 | } |
||
30 | |||
31 | void ref_sub_q15( |
||
32 | q15_t * pSrcA, |
||
33 | q15_t * pSrcB, |
||
34 | q15_t * pDst, |
||
35 | uint32_t blockSize) |
||
36 | { |
||
37 | uint32_t i; |
||
38 | |||
39 | for(i=0;i<blockSize;i++) |
||
40 | { |
||
41 | pDst[i] = ref_sat_q15( (q31_t)pSrcA[i] - pSrcB[i] ); |
||
42 | } |
||
43 | } |
||
44 | |||
45 | void ref_sub_q7( |
||
46 | q7_t * pSrcA, |
||
47 | q7_t * pSrcB, |
||
48 | q7_t * pDst, |
||
49 | uint32_t blockSize) |
||
50 | { |
||
51 | uint32_t i; |
||
52 | |||
53 | for(i=0;i<blockSize;i++) |
||
54 | { |
||
55 | pDst[i] = ref_sat_q7( (q15_t)pSrcA[i] - pSrcB[i] ); |
||
56 | } |
||
57 | } |