Lines Matching refs:new_rate
237 uint32_t new_rate = base_rate; in adjust_rates() local
246 …new_rate += (uint32_t) (((double) o->total_latency - (double) target_latency) / (double) u->adjust… in adjust_rates()
248 if (new_rate < (uint32_t) (base_rate*0.8) || new_rate > (uint32_t) (base_rate*1.25)) { in adjust_rates()
249 … rates too different, not adjusting (%u vs. %u).", o->sink_input->sink->name, base_rate, new_rate); in adjust_rates()
250 new_rate = base_rate; in adjust_rates()
252 if (base_rate < new_rate + 20 && new_rate < base_rate + 20) in adjust_rates()
253 new_rate = base_rate; in adjust_rates()
255 … if (new_rate < (uint32_t) (current_rate*0.998) || new_rate > (uint32_t) (current_rate*1.002)) { in adjust_rates()
256 …ithin 2‰ of %u Hz, forcing smaller adjustment", o->sink_input->sink->name, new_rate, current_rate); in adjust_rates()
257 … new_rate = PA_CLAMP(new_rate, (uint32_t) (current_rate*0.998), (uint32_t) (current_rate*1.002)); in adjust_rates()
259 … is %0.3f; latency is %0.2f msec.", o->sink_input->sink->name, new_rate, (double) new_rate / base_… in adjust_rates()
261 pa_sink_input_set_rate(o->sink_input, new_rate); in adjust_rates()