Lines Matching defs:band
188 int band, best_idx, power_idx = 0;
196 for (band = 1; band < NELLY_BANDS; band++) {
197 power_candidate = cand[band] - power_idx;
199 idx_table[band] = best_idx;
204 static inline float distance(float x, float y, int band)
213 int i, j, band, best_idx;
228 for (band = 1; band < NELLY_BANDS; band++) {
232 power_candidate = cand[band];
234 idx_min = FFMAX(0, cand[band] - q);
235 idx_max = FFMIN(OPT_SIZE, cand[band - 1] + q);
236 for (i = FFMAX(0, cand[band - 1] - q); i < FFMIN(OPT_SIZE, cand[band - 1] + q); i++) {
237 if ( isinf(opt[band - 1][i]) )
244 tmp = opt[band - 1][i] + distance(idx, power_candidate, band);
245 if (opt[band][idx] > tmp) {
246 opt[band][idx] = tmp;
247 path[band][idx] = j;
259 band = NELLY_BANDS - 1;
261 if (best_val > opt[band][i]) {
262 best_val = opt[band][i];
266 for (band = NELLY_BANDS - 1; band >= 0; band--) {
267 idx_table[band] = path[band][best_idx];
268 if (band) {
269 best_idx -= ff_nelly_delta_table[path[band][best_idx]];
283 int i, j, band, block, best_idx, power_idx = 0;
294 for (band = 0; band < NELLY_BANDS; band++) {
296 for (j = 0; j < ff_nelly_band_sizes_table[band]; i++, j++) {
300 cand[band] =
301 log(FFMAX(1.0, coeff_sum / (ff_nelly_band_sizes_table[band] << 7))) * 1024.0 / M_LN2;
311 for (band = 0; band < NELLY_BANDS; band++) {
312 if (band) {
313 power_idx += ff_nelly_delta_table[idx_table[band]];
314 put_bits(&pb, 5, idx_table[band]);
320 for (j = 0; j < ff_nelly_band_sizes_table[band]; i++, j++) {