diff options
author | Lajos Molnar <lajos@google.com> | 2015-04-24 17:10:07 -0700 |
---|---|---|
committer | Lajos Molnar <lajos@google.com> | 2015-04-30 16:56:10 -0700 |
commit | 3a474aa67fc31505740526dd249d96204c08bf79 (patch) | |
tree | 4db784ee57ffad037fa2ded86d0fd8b3a40173d5 /include/media/AudioTrack.h | |
parent | a8df0b716bdfda1e10790e6f7297eeff83d2e52a (diff) | |
download | frameworks_av-3a474aa67fc31505740526dd249d96204c08bf79.zip frameworks_av-3a474aa67fc31505740526dd249d96204c08bf79.tar.gz frameworks_av-3a474aa67fc31505740526dd249d96204c08bf79.tar.bz2 |
stagefright: support setting/getting playback/sync config in MediaSync
Bug: 18249558
Bug: 19666434
Bug: 20057497
Change-Id: I5868b17423d7c20cfaf4a399f3eb67bfba440605
Diffstat (limited to 'include/media/AudioTrack.h')
-rw-r--r-- | include/media/AudioTrack.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/media/AudioTrack.h b/include/media/AudioTrack.h index d361901..51d40bb 100644 --- a/include/media/AudioTrack.h +++ b/include/media/AudioTrack.h @@ -360,6 +360,11 @@ public: /* Return current source sample rate in Hz */ uint32_t getSampleRate() const; + /* Return the original source sample rate in Hz. This corresponds to the sample rate + * if playback rate had normal speed and pitch. + */ + uint32_t getOriginalSampleRate() const; + /* Set source playback rate for timestretch * 1.0 is normal speed: < 1.0 is slower, > 1.0 is faster * 1.0 is normal pitch: < 1.0 is lower pitch, > 1.0 is higher pitch @@ -749,6 +754,7 @@ protected: float mVolume[2]; float mSendLevel; mutable uint32_t mSampleRate; // mutable because getSampleRate() can update it + uint32_t mOriginalSampleRate; AudioPlaybackRate mPlaybackRate; size_t mFrameCount; // corresponds to current IAudioTrack, value is // reported back by AudioFlinger to the client |