From e83b55dc29ca16092ba02f36f55fa6e0e37fd78c Mon Sep 17 00:00:00 2001 From: Eric Laurent Date: Fri, 14 Nov 2014 10:06:21 -0800 Subject: audio policy: new getOutputForAttr() prototype. Update getOutputForAttr() prototype and group all logic dealing with audio attributes to stream type conversion in audio policy manager. getOutputForAttr(): - specifies the audio session (for future use) - returns a status code - receives either stream type (for legacy) or audio attributes - returns an updated streamtype Remove logic dealing with legacy stream types to attributes conversion from AudioTrack. Use correct type for audio sessions in other APIs (startOutput() ...). releaseOutput() specifies the audio session (for future use). Bug: 18067208. Change-Id: I1bfbe9626c04c7955d77f8a70aecfad2cb204817 --- services/audioflinger/Tracks.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'services/audioflinger/Tracks.cpp') diff --git a/services/audioflinger/Tracks.cpp b/services/audioflinger/Tracks.cpp index aa708ec..fcbf8f8 100644 --- a/services/audioflinger/Tracks.cpp +++ b/services/audioflinger/Tracks.cpp @@ -491,7 +491,7 @@ void AudioFlinger::PlaybackThread::Track::destroy() wasActive = playbackThread->destroyTrack_l(this); } if (isExternalTrack() && !wasActive) { - AudioSystem::releaseOutput(mThreadIoHandle); + AudioSystem::releaseOutput(mThreadIoHandle, mStreamType, (audio_session_t)mSessionId); } } } -- cgit v1.1