Make flush() update parameters, and make Sonic flushable
Previously it was necessary to create a new Sonic instance every time the processor was flushed. Add a flush() method to Sonic so that it can be reused when seeking. It still needs to be recreated when parameters change. SonicAudioProcessor and SilenceSkippingAudioProcessor have methods for setting parameters that are documented as taking effect after a call to flush(), but actually the value returned by isActive() was updated immediately. Track the pending values and apply them in flush() to fix this. ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=191442336
Showing
with
64 additions
and
17 deletions
Please
register
or
sign in
to comment