Lines Matching refs:dither
27 double scale = s->dither.noise_scale; in swri_get_dither()
39 switch(s->dither.method){ in swri_get_dither()
42 av_assert0(s->dither.method < SWR_DITHER_NB); in swri_get_dither()
54 switch(s->dither.method){ in swri_get_dither()
56 av_assert0(s->dither.method < SWR_DITHER_NB); in swri_get_dither()
84 if (s->dither.method > SWR_DITHER_TRIANGULAR_HIGHPASS && s->dither.method <= SWR_DITHER_NS) in swri_dither_init()
95 …if(in_fmt == AV_SAMPLE_FMT_S32 && out_fmt == AV_SAMPLE_FMT_S32 && (s->dither.output_sample_bits&31… in swri_dither_init()
100 scale *= s->dither.scale; in swri_dither_init()
102 if (out_fmt == AV_SAMPLE_FMT_S32 && s->dither.output_sample_bits) in swri_dither_init()
103 scale *= 1<<(32-s->dither.output_sample_bits); in swri_dither_init()
106 s->dither.method = 0; in swri_dither_init()
110 s->dither.ns_pos = 0; in swri_dither_init()
111 s->dither.noise_scale= scale; in swri_dither_init()
112 s->dither.ns_scale = scale; in swri_dither_init()
113 s->dither.ns_scale_1 = scale ? 1/scale : 0; in swri_dither_init()
114 memset(s->dither.ns_errors, 0, sizeof(s->dither.ns_errors)); in swri_dither_init()
117 if (llabs(s->out_sample_rate - f->rate)*20 <= f->rate && f->name == s->dither.method) { in swri_dither_init()
119 s->dither.ns_taps = f->len; in swri_dither_init()
121 s->dither.ns_coeffs[j] = f->coefs[j]; in swri_dither_init()
122 …s->dither.ns_scale_1 *= 1 - exp(f->gain_cB * M_LN10 * 0.005) * 2 / (1<<(8*av_get_bytes_per_sample(… in swri_dither_init()
126 if (!filters[i].coefs && s->dither.method > SWR_DITHER_NS) { in swri_dither_init()
128 s->dither.method = SWR_DITHER_TRIANGULAR_HIGHPASS; in swri_dither_init()