google/ExoPlayer — pull request #213 by martinbonnin (2014-12-19 15:50:51+00:00)
Title: better handling of input format change for non-adaptive codecs

* this fixes a bug when switching from HE-AAC 22050Hz to AAC 44100Hz (the AudioTrack was not reset and we were trying to send a bad number of bytes, triggering a "AudioTrack.write() called with invalid size" error)
* this also improves quality switches, making it almost seamless