diff options
author | Glenn Kasten <gkasten@google.com> | 2014-01-13 08:53:36 -0800 |
---|---|---|
committer | Glenn Kasten <gkasten@google.com> | 2014-01-14 16:01:20 -0800 |
commit | 2b2165c75790050810460c8de3f414876bce4c0e (patch) | |
tree | d0051f908567bbd815ae5a163443f1f5809493ba /include/media/AudioTrack.h | |
parent | 23a7545c4de71e989c2d8ebf1d5b9dcf463c36a9 (diff) | |
download | frameworks_av-2b2165c75790050810460c8de3f414876bce4c0e.zip frameworks_av-2b2165c75790050810460c8de3f414876bce4c0e.tar.gz frameworks_av-2b2165c75790050810460c8de3f414876bce4c0e.tar.bz2 |
Unify comments between AudioTrack and AudioRecord
Change-Id: I00a1025e2891a1c96218b3c2187eaddda6614ebc
Diffstat (limited to 'include/media/AudioTrack.h')
-rw-r--r-- | include/media/AudioTrack.h | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/include/media/AudioTrack.h b/include/media/AudioTrack.h index 4fe537f..c430233 100644 --- a/include/media/AudioTrack.h +++ b/include/media/AudioTrack.h @@ -160,7 +160,7 @@ public: * sampleRate: Data source sampling rate in Hz. * format: Audio format (e.g AUDIO_FORMAT_PCM_16_BIT for signed * 16 bits per sample). - * channelMask: Channel mask. + * channelMask: Channel mask, such that audio_is_output_channel(channelMask) is true. * frameCount: Minimum size of track PCM buffer in frames. This defines the * application's contribution to the * latency of the track. The actual size selected by the AudioTrack could be @@ -338,7 +338,7 @@ public: */ status_t setSampleRate(uint32_t sampleRate); - /* Return current source sample rate in Hz, or 0 if unknown */ + /* Return current source sample rate in Hz */ uint32_t getSampleRate() const; /* Enables looping and sets the start and end points of looping. @@ -363,7 +363,7 @@ public: /* Sets marker position. When playback reaches the number of frames specified, a callback with * event type EVENT_MARKER is called. Calling setMarkerPosition with marker == 0 cancels marker * notification callback. To set a marker at a position which would compute as 0, - * a workaround is to the set the marker at a nearby position such as ~0 or 1. + * a workaround is to set the marker at a nearby position such as ~0 or 1. * If the AudioTrack has been opened with no callback function associated, the operation will * fail. * @@ -664,9 +664,10 @@ protected: float mVolume[2]; float mSendLevel; mutable uint32_t mSampleRate; // mutable because getSampleRate() can update it. - size_t mFrameCount; // corresponds to current IAudioTrack - size_t mReqFrameCount; // frame count to request the next time a new - // IAudioTrack is needed + size_t mFrameCount; // corresponds to current IAudioTrack, value is + // reported back by AudioFlinger to the client + size_t mReqFrameCount; // frame count to request the first or next time + // a new IAudioTrack is needed, non-decreasing // constant after constructor or set() audio_format_t mFormat; // as requested by client, not forced to 16-bit @@ -716,6 +717,7 @@ protected: sp<IMemory> mSharedBuffer; uint32_t mLoopPeriod; // in frames, zero means looping is disabled + uint32_t mMarkerPosition; // in wrapping (overflow) frame units bool mMarkerReached; uint32_t mNewPosition; // in frames |