| 158 | } |
| 159 | |
| 160 | static unsigned int rms(const int *data) |
| 161 | { |
| 162 | int i; |
| 163 | unsigned int res = 0x10000; |
| 164 | int b = 10; |
| 165 | |
| 166 | for (i=0; i < 10; i++) { |
| 167 | res = (((0x1000000 - data[i]*data[i]) >> 12) * res) >> 12; |
| 168 | |
| 169 | if (res == 0) |
| 170 | return 0; |
| 171 | |
| 172 | while (res <= 0x3fff) { |
| 173 | b++; |
| 174 | res <<= 2; |
| 175 | } |
| 176 | } |
| 177 | |
| 178 | return t_sqrt(res) >> b; |
| 179 | } |
| 180 | |
| 181 | static void do_output_subblock(RA144Context *ractx, const uint16_t *lpc_coefs, |
| 182 | int gval, GetBitContext *gb) |
no test coverage detected