summaryrefslogtreecommitdiffstats
path: root/media/libmedia/IAudioFlingerClient.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Implement audio device callbackEric Laurent2015-05-061-0/+2
| | | | | | | | | | | | | | | | | | | | Add class AudioSystem::AudioDeviceCallback notifying AudioSystem clients upon device selection change on a given input or output thread. Maintain a list of installed callback per I/O handle in AudioSystem and call registered callbacks when an OPEN of CONFIG_CHANGED event is received on IAudioFlingerClient::ioConfigChanged(). Add methods to AudioTrack and AudioRecord to add and remove device change callbacks. Add methods to AudioTrack and AudioRecord to query currently selected device. ioConfigChanged() events now convey the audio patch describing the input or output thread routing. Fix AudioRecord failure to start when invalidation is handled by start(). Change-Id: I9e938adf025fa712337c63b1e02a8c18f2a20d39
* AudioSystem: refactor audio config cache and callbacksEric Laurent2015-05-011-33/+16
| | | | | | | | | | | | | | | Clean up implementation of audio configuration cache and callback events from AudioFlinger: - Define class AudioIoDescriptor for audio input and output configurations outside of AudioSystem class. - Do not use void * but an AudioIoDescriptor as argument to audio config callbacks from AudioFlinger. - Remove unused configuration events. - Move AudioSystem audio input and output cache from static singletons to members of AudioFlingerClient subclass. Change-Id: I67c196c32c09ce2756af0755ee1fe631040c3270
* namespace does not need a closing semicolonGlenn Kasten2015-03-231-1/+1
| | | | Change-Id: Ie8f9d42fc061f6d558f23b98414e04eb3d14b376
* When passing a size_t via binder, use 64-bits unconditionallyGlenn Kasten2014-02-131-2/+2
| | | | | | | | | 64-bits is almost always over-kill. But it's easier and cleaner to change the binder code to be accurate, than to rename all the the API parameter types to be 32-bit. Bug: 12381724 Change-Id: Ib8f198d814a2027760ef24e9e3feacee21a973b1
* Use correct type for OutputDescriptor::formatGlenn Kasten2013-07-301-1/+1
| | | | Change-Id: Ide608ef452d57da29b708180d90470361c123d1d
* Use standard name and type for channel maskGlenn Kasten2013-07-241-2/+2
| | | | | | Former name 'channels' was ambiguous with respect to channel count. Change-Id: I716f792d95a7e0c787d27514ad6e93dbcef8a415
* Line length 100Glenn Kasten2012-11-011-1/+2
| | | | Change-Id: Ib28fd7b9ce951a6933f006e7f8812ba617625530
* Whitespace and indentationGlenn Kasten2012-03-131-1/+1
| | | | | | | | | | | | | | Fix indentation to be multiple of 4. Make it easier to search: sp< not sp < to "switch (...)" instead of "switch(...)" (also "if" and "while") Remove redundant blank line at start or EOF. Remove whitespace at end of line. Remove extra blank lines where they don't add value. Use git diff -b or -w to verify. Change-Id: I966b7ba852faa5474be6907fb212f5e267c2874e
* IAudioFlingerClient::ioConfigChanged param2 constGlenn Kasten2012-03-061-4/+4
| | | | | | | | | The 3rd parameter (param2) to AudioFlingerClient::ioConfigChanged is used as an input. So changed it from void * to const void *. It is then cast to const OutputDescriptor * or const audio_stream_type_t * depending on the event. Change-Id: Ieec0d284f139b74b3389b5ef69c7935a8e5650ee
* Use audio_io_handle_t consistently instead of intGlenn Kasten2012-02-081-3/+3
| | | | | | | | Other: - add a comment to nextUniqueId - made ThreadBase::mId const, since it is only assigned in constructor. Change-Id: I4e8b7bec4e45badcde6274d574b8a9aabd046837
* Use NULL not 0 for raw pointersGlenn Kasten2012-02-031-1/+1
| | | | | | Use if (p != NULL) instead of if (ptr) Change-Id: Iaec3413a59ccbf233c98fcd918cc7d70ac5da9fa
* Rename (IF_)LOGV(_IF) to (IF_)ALOGV(_IF) DO NOT MERGESteve Block2011-10-261-2/+2
| | | | | | | See https://android-git.corp.google.com/g/#/c/143865 Bug: 5449033 Change-Id: I0122812ed6ff6f5b59fe4a43ab8bff0577adde0a
* Fix issue 2001214: AudioFlinger and AudioPolicyService interfaces should not ↵Eric Laurent2009-08-071-5/+4
| | | | | | | use pointers as handles to inputs and outputs. Use integers instead of void* as input/output handles at IAudioFlinger and IAudioPolicyService interfaces. AudioFlinger maintains an always increasing count of opened inputs or outputs as unique ID.
* Fix issue 1795088 Improve audio routing codeEric Laurent2009-07-231-7/+38
| | | | | | | Initial commit for review. Integrated comments after patch set 1 review. Fixed lockup in AudioFlinger::ThreadBase::exit() Fixed lockup when playing tone with AudioPlocyService startTone()
* some work to try to reduce the code size of some native librariesMathias Agopian2009-05-261-6/+0
| | | | | | | | | | | | | | | | | - make sure that all binder Bn classes define a ctor and dtor in their respective library. This avoids duplication of the ctor/dtor in libraries where these objects are instantiated. This is also cleaner, should we want these ctor/dtor to do something one day. - same change as above for some Bp classes and various other non-binder classes - moved the definition of CHECK_INTERFACE() in IInterface.h instead of having it everywhere. - improved the CHECK_INTERFACE() macro so it calls a single method in Parcel, instead of inlining its code everywhere - IBinder::getInterfaceDescriptor() now returns a "const String16&" instead of String16, which saves calls to String16 and ~String16 - implemented a cache for BpBinder::getInterfaceDescriptor(), since this does an IPC. HOWEVER, this method never seems to be called. The cache makes BpBinder bigger, so we need to figure out if we need this method at all.
* move libbinder's header files under includes/binderMathias Agopian2009-05-201-1/+1
|
* Fix issue 1745312: Various cleanups in media frameworkEric Laurent2009-04-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | AudioTrack, AudioRecord: - remove useless mAudioFlinger member of AudioTrack and AudioRecord. - signal cblk.cv condition in stop() method to speed up stop completion. - extend wait condition timeout in obtainBuffer() when waitCount is -1 to avoid waking up callback thread unnecessarily AudioFlinger: - remove some warnings in AudioFlinger.cpp. - remove function AudioFlinger::MixerThread::removetrack_l() as its content is never executed. - remove useless call to setMasterVolume in AudioFlinger::handleForcedSpeakerRoute(). - Offset VOICE_CALL stream volume to reflect actual volume that is never 0 in hardware (this fix has been made in the open source): 0.01 + v * 0.99. AudioSystem.java: - correct typo in comment IAudioflinger, IAudioFlingerClient: - make AudioFlinger binder interfaces used for callbacks ONEWAY. AudioHardwareInterface: - correct routeStrings[] table in AudioHardwareInteface.cpp
* auto import from //depot/cupcake/@135843The Android Open Source Project2009-03-031-0/+77
|
* auto import from //depot/cupcake/@135843The Android Open Source Project2009-03-031-77/+0
|
* auto import from //branches/cupcake/...@131421The Android Open Source Project2009-02-131-8/+4
|
* auto import from //branches/cupcake/...@130745The Android Open Source Project2009-02-101-0/+81