summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Merge "Remove dead code in libmedia"Glenn Kasten2012-07-135-29/+0
|\
| * Remove dead code in libmediaGlenn Kasten2012-07-125-29/+0
| | | | | | | | Change-Id: I7d8201590cda29c9fa99662a4fdba222091febfe
* | Add tid parameter to IAudioFlinger::openRecordGlenn Kasten2012-07-125-9/+20
| | | | | | | | | | | | Not yet implemented Change-Id: I35523fb15ad71727ecc9f4bb870f07e4b7397dc4
* | Simplify AudioRecord::getInputFramesLost()Glenn Kasten2012-07-123-8/+3
|/ | | | | | This also fixes a benign race in reading mActive without a lock. Change-Id: I19e953d4f275e5c266ca1ca3fece7b6c02ad1707
* Remove dead codeGlenn Kasten2012-07-112-9/+0
| | | | Change-Id: If22a6c4e572b0734eba0c5a7ce29a2c61c581e5d
* Fix check for invalid channel countGlenn Kasten2012-07-111-2/+2
| | | | Change-Id: Id9e3dce0e3d5971786212d3f70e17a17e32ce92b
* Record overflow cleanupGlenn Kasten2012-07-102-4/+5
| | | | | | Add comments and rename one method for clarity Change-Id: I04a9147e46e88a072256c0211b112d52202419e2
* Use audio_channel_mask_t more placesGlenn Kasten2012-07-109-63/+59
| | | | | | | | | | Use it in AudioSystem::getOutput(), AudioSystem::getInput(), IAudioPolicyService::getOutput(), IAudioPolicyService::getInput(), and various other places in AudioFlinger. Not done: AudioTrack and OutputDescriptor. Change-Id: I70e83455820bd8f05dafd30c63d636c6a47cd172
* Merge "audio policy: fix delayed command insertion"Eric Laurent2012-07-101-17/+14
|\
| * audio policy: fix delayed command insertionEric Laurent2012-07-091-17/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When inserting a delayed command in the audio policy service command thread queue, later similar commands are filtered out. In case of volume commands and delayed unmuting, this can cause a problem where a new volume command can cause the timing of a delayed unmuting command to not be honored. This change makes that a volume command gets the time stamp of any delayed command it replaces. Bug 6720482. Change-Id: I216f85ac0ea46e4a046d3483e9e9b7ffe6c34a08
* | Add comments on use of volatile for track countGlenn Kasten2012-07-101-4/+7
| | | | | | | | | | | | and add acquire load at the read Change-Id: Ib41a58f5b1f6af87a8bd63d3f77d2ec0e48cb479
* | Remove 'volatile' from mMute and add commentsGlenn Kasten2012-07-101-2/+6
| | | | | | | | Change-Id: I386ba27b2305a397aba70331c6bf0d35ea727cf6
* | Whitespace and indentationGlenn Kasten2012-07-102-14/+11
| | | | | | | | Change-Id: I424052b4ff9218147a5cfc8e6dcd67fe8105d229
* | Move constant initializations from onFirstRef() to constructorGlenn Kasten2012-07-101-4/+2
| | | | | | | | Change-Id: I57f55b0bd1edee105c58c3a055f95f1e4a2c9646
* | Merge "AudioFlinger::getBuffer() always returns non-NULL"Glenn Kasten2012-07-102-4/+7
|\ \
| * | AudioFlinger::getBuffer() always returns non-NULLGlenn Kasten2012-07-092-4/+7
| | | | | | | | | | | | Change-Id: I543d3db507597cacbfdad5d9ea71732137fe54fb
* | | Merge "Move declarations of local variables to first use"Glenn Kasten2012-07-101-1/+1
|\ \ \ | |/ / |/| |
| * | Move declarations of local variables to first useGlenn Kasten2012-06-211-1/+1
| | | | | | | | | | | | Change-Id: I48b193a742b32b6746aa938b84dc405124a6a5c3
* | | Fix buildGlenn Kasten2012-07-091-4/+4
| | | | | | | | | | | | | | | | | | Revert after system/core audio_devices_t is submitted Change-Id: I5a8ee1a7b711e834501e927f41c62efa6a6600b6
* | | Only write to mDevice onceGlenn Kasten2012-07-092-11/+29
| | | | | | | | | | | | | | | | | | | | | This fixes a bug where readers might see intermediate values. Also add comments about how mStandby and mDevice are used. Change-Id: Idc84e56c21381a45137a2ca5ff9c57d437201869
* | | Remove debug code HAVE_REQUEST_PRIORITY and SOAKERGlenn Kasten2012-07-034-75/+1
| |/ |/| | | | | Change-Id: I73a2afe72d8acb53e57e6b4e6fb5133e22b7875a
* | Merge "audioflinger: fix effect disconnect deadlock"Eric Laurent2012-07-032-60/+97
|\ \
| * | audioflinger: fix effect disconnect deadlockEric Laurent2012-07-032-60/+97
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix possible deadlock when several EffectHandles on the same EffectModule are destroyed simultaneously: A wp on an EffectHandle should not be promoted to a local sp with ThreadBase mutex held as the EffectHandle destructor can be called when the sp gets out of scope which will call ThreadBase::disconnectEffect() and try to acquire the mutex. Use raw pointers instead of weak pointers for the list of handles on an EffectModule. Bug 6679606. Change-Id: Ice8b602fb03a7d363c44ce3dced8a53540d96270
* | | am ffb82943: Reconcile with jb-releaseThe Android Open Source Project2012-07-030-0/+0
|\ \ \ | |/ / |/| | | | | * commit 'ffb829430ff20ccd6c13e6ed894f2373b2d93939':
| * | Reconcile with jb-releaseThe Android Open Source Project2012-07-030-0/+0
| |\ \ | | | | | | | | | | | | Change-Id: I7c52b8e82465f28b32e8ebf6df56c258458f2cd3
| | * \ merge in jb-release history after reset to jb-devThe Android Automerger2012-07-020-0/+0
| | |\ \
* | | | | Use audio_channel_mask_t more consistentlyGlenn Kasten2012-07-039-33/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In IAudioFlinger::createTrack() and IAudioFlinger::openRecord(), declare input parameter to use correct type audio_channel_mask_t. In IAudioFlinger::getInputBufferSize(), input parameter is now channel mask instead of channel count. Remove unused IAudioFlinger::channelCount(audio_io_handle_t). In AudioRecord::getMinFrameCount() and AudioSystem::getInputBufferSize(), input parameter is channel mask instead of channel count. Change-Id: Ib2f1c29bea70f016b3cfce83942ba292190ac965
* | | | | Remove longStandbyExitGlenn Kasten2012-07-032-12/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It was never set (the assignment was within an "if" that was never true). Change-Id: I01cc68e9df6b190eece621b2aa9858b4361880ce
* | | | | Fix uninitialized field EffectModule::mPinnedGlenn Kasten2012-07-032-7/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also mark EffectModule::mId and EffectModule::mSessionId const, and document the initialization of other fields in EffectModule. Change-Id: Ic1ca008e75e9b5924743ffc35bef80057f3a0669
* | | | | Compare sp<> to 0 and raw pointers to NULLGlenn Kasten2012-07-021-8/+8
| | | | | | | | | | | | | | | | | | | | Change-Id: I50ff8a010d349d1d7e3dffa04a6331814c2128b0
* | | | | Merge "Fixed a video editor crash due to "divided by 0""James Dong2012-07-021-4/+8
|\ \ \ \ \
| * | | | | Fixed a video editor crash due to "divided by 0"James Dong2012-06-291-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The crash was because the video sample was too short and has 0 duration (or a single frame video). This patch is just simply not to support 0 duration video for editing. Change-Id: I2c7ff78b1e884a4d3a5051f87cdbeeb5dc3078a6 related-to-bug: 6670656
* | | | | | am dbbd5b86: am 109347d4: audioflinger: fix regression in attachAuxEffect().Eric Laurent2012-07-021-4/+1
|\ \ \ \ \ \ | | |/ / / / | |/| | | | | | | | | | | | | | | | * commit 'dbbd5b860a3a26bea3376410f75f27530d9cd10b': audioflinger: fix regression in attachAuxEffect().
| * | | | | am 109347d4: audioflinger: fix regression in attachAuxEffect().Eric Laurent2012-07-021-4/+1
| |\ \ \ \ \ | | | |/ / / | | |/| | | | | | | | | | | | | | | * commit '109347d421413303eb1678dd9e2aa9d40acf89d2': audioflinger: fix regression in attachAuxEffect().
| | * | | | audioflinger: fix regression in attachAuxEffect().Eric Laurent2012-07-021-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 717e1286 introduced a regression in PlaybackThread::Track::attachAuxEffect() when called with an effect ID of 0 to detach the auxiliary effect. It is normal in this case that AudioFlinger::getEffectThread_l() returns 0. Bug 6768757. Change-Id: I7430bd1aad2f68da38f7c3e4794e7ad657bfc6be
* | | | | | am 651f9e7c: am 717e1286: audioflinger: fix auxiliary effect attachmentEric Laurent2012-07-012-0/+65
|\ \ \ \ \ \ | |/ / / / / | | | / / / | |_|/ / / |/| | | | * commit '651f9e7c972b58a49066081187161268bcf9237a': audioflinger: fix auxiliary effect attachment
| * | | | am 717e1286: audioflinger: fix auxiliary effect attachmentEric Laurent2012-07-012-0/+65
| |\ \ \ \ | | |/ / / | | | | | | | | | | | | | | | * commit '717e128691f083a9469a1d0e363ac6ecd5c65d58': audioflinger: fix auxiliary effect attachment
| | * | | audioflinger: fix auxiliary effect attachmentEric Laurent2012-06-292-0/+65
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Auxiliary effects (Reverb) are global effects and as such follow the default rule which is to attach them to the output thread that handles music streams by default. This causes a problem when several threads are eligible to handle music streams as tracks can be attached to either thread based on criteria unknown when teh effect is created. The fix consists in moving the auxiliary effect if necessary when an AudioTrack is attached to it and this track is not on the same output thread. Bug 6608561. Change-Id: Ib32c3cabc731b2046aba728be1771982999c6069
* | | | | Fixed a media server crash due to unintialized mRecord member variableJames Dong2012-06-291-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | mRecord is not properly initialized if the call to AudioRecord::getMinFrameCount() fails. media server crashes when the unintialized mRecord object is deleted in AudioSource's destructor. Change-Id: Ia89222789d044c11c9957a99725bc89f9c709e17 related-to-bug: 6744014
* | | | | Add mode when open(O_CREAT) is used.Nick Kralevich2012-06-265-5/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When creating a new file using open(..., O_CREAT), it is an error to fail to specify a creation mode. If a mode is not specified, a random stack provided value is used as the "mode". This will become a compile error in a future Android change. Change-Id: I36a3d67d294a915c1f79632a1b0ba45edd1214b1
* | | | | Merge "AudioRecord comments"Glenn Kasten2012-06-251-25/+31
|\ \ \ \ \
| * | | | | AudioRecord commentsGlenn Kasten2012-06-251-25/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Group the private fields according to how they are used Change-Id: I7ce3d0939510c10f34bd91a55f6e03afc8e7d43c
* | | | | | Merge "Remove acoustics from AudioSystem::getInput()"Glenn Kasten2012-06-257-16/+4
|\ \ \ \ \ \
| * | | | | | Remove acoustics from AudioSystem::getInput()Glenn Kasten2012-06-257-16/+4
| |/ / / / / | | | | | | | | | | | | | | | | | | Change-Id: I29fb3ee5664c1f0ee0409c1bb2be087ecca637db
* | | | | | Merge "audioflinger: fix setStreamOutput()"Eric Laurent2012-06-252-13/+4
|\ \ \ \ \ \ | |/ / / / / |/| | | | |
| * | | | | audioflinger: fix setStreamOutput()Eric Laurent2012-06-202-13/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | AudioFlinger::setStreamOutput() should also work for direct outputs. Also ignore the destination output specified to match the expected behavior which is to invalidate all tracks using the specified stream type so that they can be re created on the correct ouput thread. Do not send STREAM_CONFIG_CHANGED event wich is ignored by AudioSystem anyway since the stream to output cache has been removed. Change-Id: I13d9d47922923b630dd755717875424c16be4637
* | | | | | Use audio_channel_mask_t in AudioRecordGlenn Kasten2012-06-252-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I9e1b918b2635d961604a4a9d88eb1c7179a167a7
* | | | | | Remove unused AudioRecord::channels()Glenn Kasten2012-06-251-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It was declared but never implemented or called. Change-Id: If5846147fcbd7f6d4187971e2044dd6fd3252b42
* | | | | | Include what you useGlenn Kasten2012-06-252-28/+11
| | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I12ef9367d05dbe069c037b1b4acd6347a8cf3ece
* | | | | | Merge "Remove AudioRecord record_flags"Glenn Kasten2012-06-253-24/+3
|\ \ \ \ \ \