History log of /frameworks/ex/variablespeed/src/com/android/ex/variablespeed/EngineParameters.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
dc442b4d99512bf7c41ee5ceae6c93a3c3568b57 31-Aug-2011 Flavio Lerda <flerda@google.com> Allows selecting the audio stream used for playback.

Adds setAudioStreamType() to the MediaPlayerProxy interface and
implements it in the variable speed player.

Bug: 5240848
Change-Id: I1bb9fdbee7aa6113c5d5d5a8000e9794800fad9f
/frameworks/ex/variablespeed/src/com/android/ex/variablespeed/EngineParameters.java
0bd6ec5bc06b869131ee0facf38ff02f81f65c10 26-Jul-2011 Hugo Hudson <hugohudson@google.com> Playback now handles any sample rate and channel combo.

Main stuff
- Delayed construction of audio player until after sample rate and
channels have been read from the first callback.
- Removed all sample rate and channels from outward facing api.
- Remove pause playing and prefetch duration and sample rate hacky code.
- Fixes handling of any sample rate by removing switch statement.
- Fixes a HORRIBLE bug introduced in last cl where I was creating the
callback context on the stack inside a method call, and using it a
pointer to it long after the object had been erased from the stack.
[worse yet: it still mostly worked fine!]

Other
- Fixes an obvious failure case of all tests - duh - I was calling setUp()
before setting the executor properly, so they were giving NPEs.
- Correct calculation of totalDuration now done on first decode callback.
- This will let us remove MediaPlayer from prepare() in follow up.
- Initializing the engine outside of the PlaybackRunnable, is cleaner.
- Adds static methods for reading duration and position, again so that
follow up can have accurate get current position rather than best guess.
- Buffers in use for decoding also not created until first decode callback.
- Introduces some wicked-cool OpenSL macro to log api calls, make the
api calls and check the result value.

Bug: 5048252
Bug: 5048257
Change-Id: I60705fa6c6ab29a35740f22bef76450e8c1d25a2
/frameworks/ex/variablespeed/src/com/android/ex/variablespeed/EngineParameters.java
b83ad73794088498d6d38cd3b4fc9311f505d051 15-Jul-2011 Hugo Hudson <hugohudson@google.com> Initial check-in of variable speed playback library.

Contains an implementation of time-domain audio scaler, for
pitch-invariant speed up and slow-down of audio.

Contains wrapper library using OpenSLES to pump audio from
encoded stream (mp3 file etc) through audio decoder then
through time scaler and out to media player.

This is written as a jni library with jni hooks to allow
driving of this from the Java side.

The other part of this cl is the Java wrapper. There is a
new interface MediaPlayerProxy, containing a subset of the
methods found on the MediaPlayer. The VariableSpeed class
provides a concrete implementation of this interface
adapting to the jni code.

Change-Id: I518d8bf703488628c00730241a08ebfb67588ca6
/frameworks/ex/variablespeed/src/com/android/ex/variablespeed/EngineParameters.java