summaryrefslogtreecommitdiffstats
path: root/include/private
diff options
context:
space:
mode:
authorEric Laurent <elaurent@google.com>2009-07-07 07:10:45 -0700
committerEric Laurent <elaurent@google.com>2009-07-07 07:10:45 -0700
commit88e209dcf8c2ebddda5c272f46d1bd5478bc639c (patch)
tree0b4bc797c237a5179be63ee9c3716e8213fc08b6 /include/private
parent37ea71122579e9e2ad1f91b3eca5e4d436b54ea9 (diff)
downloadframeworks_base-88e209dcf8c2ebddda5c272f46d1bd5478bc639c.zip
frameworks_base-88e209dcf8c2ebddda5c272f46d1bd5478bc639c.tar.gz
frameworks_base-88e209dcf8c2ebddda5c272f46d1bd5478bc639c.tar.bz2
Fix issue 1743700: AudioTrack: setPlaybackRate can not set the playback rate to twice of the ouputSR
Store sample rate on 32 bits instead of 16 bits in audio_track_cblk_t. Removed sampleRate() methods from AudioTrack and AudioRecord: replaced by getSampleRate(). AudioTrack::setSampleRate() no returns a status.
Diffstat (limited to 'include/private')
-rw-r--r--include/private/media/AudioTrackShared.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/include/private/media/AudioTrackShared.h b/include/private/media/AudioTrackShared.h
index bda969c..496a739 100644
--- a/include/private/media/AudioTrackShared.h
+++ b/include/private/media/AudioTrackShared.h
@@ -26,7 +26,6 @@ namespace android {
// ----------------------------------------------------------------------------
-#define MAX_SAMPLE_RATE 65535
#define THREAD_PRIORITY_AUDIO_CLIENT (ANDROID_PRIORITY_AUDIO)
// Maximum cumulated timeout milliseconds before restarting audioflinger thread
#define MAX_STARTUP_TIMEOUT_MS 3000 // Longer timeout period at startup to cope with A2DP init time
@@ -55,9 +54,9 @@ struct audio_track_cblk_t
uint16_t volume[2];
uint32_t volumeLR;
};
- uint16_t sampleRate;
- uint16_t channels;
- int16_t flowControlFlag; // underrun (out) or overrrun (in) indication
+ uint32_t sampleRate;
+ uint8_t channels;
+ uint8_t flowControlFlag; // underrun (out) or overrrun (in) indication
uint8_t out; // out equals 1 for AudioTrack and 0 for AudioRecord
uint8_t forceReady;
uint16_t bufferTimeoutMs; // Maximum cumulated timeout before restarting audioflinger