summaryrefslogtreecommitdiffstats
path: root/media/libmedia
Commit message (Collapse)AuthorAgeFilesLines
* stagefright: discard audio at start of captureEric Laurent2012-10-221-1/+1
| | | | | | | | | | | The new camcorder start sound is longer than previous one and we must discard more audio when capture starts. Ideally, camcorder should use synchronous record start. Bug 7394330. Change-Id: I219b4e231aba706776dc7ccc4f1c996eaf22f61a
* Support querying active record sourcesJean-Michel Trivi2012-10-102-0/+26
| | | | | | | | | Add support for querying whether there is currently a recording underway from the specified audio source. Bug 7314859 Change-Id: I986b231a10ffd368b08ec2f9c7f348d28eaeb892
* Implement android.media.AudioManager.getProperty()Glenn Kasten2012-09-252-1/+43
| | | | | Bug: 6635041 Change-Id: I3386a4a6c226bc4eceaf65556119e4fb15f73224
* Remove legacy code and APIs in wifi display related code.Andreas Huber2012-09-211-25/+0
| | | | Change-Id: Ia010e7a00534f9356b3247369d0ffd65591d91aa
* HDCP module binderizedAndreas Huber2012-09-191-0/+15
| | | | Change-Id: I866768b1e3f3b232f1934a35b65f66befc12f3f6
* audioflinger: send priority request from a threadEric Laurent2012-09-131-2/+1
| | | | | | | | | | | | | | | | | | | When creating a fast AudioTrack, a request is sent to SchedulingPolicyService to elevate the requesting thread priority. This generates a binder call into system_server process and to a JAVA service via JNI. If the thread from which the track was created is in the system_server process and does not have the "can call java" attribute, a crash occurs because the binder optimization reuses the same thread to process the returning binder call and no JNI env is present. The fix consists in sending the priority change request from the AudioFlinger mixer thread, not from the binder thread. This also reverts the workaround in commit 73431968 Bug 7126707. Change-Id: I3347adf71ffbb56ed8436506d4357eab693078a3
* Workaround for track recreation bugJean-Michel Trivi2012-09-121-1/+2
| | | | | | | | Ignore thread can call Java parameter to work around bug where AudioTrack instance gets recreated when key clicks are enabled and WFD gets turned on, with the wrong parameters. Change-Id: Ia42c8704b46fe3ffea560b05b60939fa2e4b29e1
* am e7c992c6: am 5abc91d6: Merge "Fix libmedia and libstagefright to get ↵Elliott Hughes2012-09-092-2/+1
|\ | | | | | | | | | | | | expat header files from the approved location." * commit 'e7c992c675e0075cd60b0b11c06d5956e3ddd7a3': Fix libmedia and libstagefright to get expat header files from the approved location.
| * am 5abc91d6: Merge "Fix libmedia and libstagefright to get expat header ↵Elliott Hughes2012-09-092-2/+1
| |\ | | | | | | | | | | | | | | | | | | files from the approved location." * commit '5abc91d61718e334e05c6d4858bd868bd5a5769c': Fix libmedia and libstagefright to get expat header files from the approved location.
| | * Fix libmedia and libstagefright to get expat header files from the approved ↵Elliott Hughes2012-09-092-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | location. Found during a libexpat upgrade. Change-Id: I9e5abd502a884975d898486edde374fb2519164e
* | | Merge "AudioRecord: Fix minimum frame count calculation." into jb-mr1-devEric Laurent2012-09-071-1/+1
|\ \ \
| * | | AudioRecord: Fix minimum frame count calculation.Eric Laurent2012-09-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | AudioRecord::set() was calling getMinFrameCount() with a channel count instead of a channel mask. Change-Id: Iabace7686426430fd53deac0c71b0c36aa64171c
* | | | Update remote display API.Jeff Brown2012-09-051-5/+5
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Renamed disconnect() to dispose() to emphasize the fact that this method is intended to clean up the IRemoteDisplay completely, not just temporarily disconnect the current client (which might be useful someday). Other minor tweaks. Change-Id: I1209639eb0cd8af09c724206642d7e52aab48257
* | | Implement remote display service stubs.Jeff Brown2012-09-054-1/+192
| | | | | | | | | | | | Change-Id: I582ed000026bba6d116db8304e15a3c52f8a9a01
* | | Merge "Added an additional virtual method IStreamSource::flags()." into ↵Andreas Huber2012-08-311-0/+16
|\ \ \ | | | | | | | | | | | | jb-mr1-dev
| * | | Added an additional virtual method IStreamSource::flags().Andreas Huber2012-08-311-0/+16
| | | | | | | | | | | | | | | | Change-Id: I89e62d84328e12f08c8f73cbfd53cfb42569de97
* | | | Update audio commentsGlenn Kasten2012-08-301-1/+1
|/ / / | | | | | | | | | Change-Id: Ie7504d0ddb252f7e4d4f99ed0b44cfc7b1049816
* | | Only run the wifi display RTSP server on demand, and only on the wifi directAndreas Huber2012-08-301-4/+14
| | | | | | | | | | | | | | | | | | interface. Change-Id: I7d3c44cb79cd40e73499f2d7ccf35c69b628e6d7
* | | Merge "Initial checkin of support for acting as a wifi display source" into ↵Andreas Huber2012-08-291-0/+15
|\ \ \ | | | | | | | | | | | | jb-mr1-dev
| * | | Initial checkin of support for acting as a wifi display sourceAndreas Huber2012-08-291-0/+15
| | | | | | | | | | | | | | | | Change-Id: I08f17efa0c7d007e17408feb7d4fbef0a19f531a
* | | | Preliminary support for HDCP as a binder service for wifi display support.Andreas Huber2012-08-292-0/+207
|/ / / | | | | | | | | | Change-Id: Ie0de1c086c629a668d1c7863992eef56fb94157c
* | | Merge "Revert "Swap the order of creating IAudioTrack and thread"" into ↵Glenn Kasten2012-08-201-5/+10
|\ \ \ | | | | | | | | | | | | jb-mr1-dev
| * | | Revert "Swap the order of creating IAudioTrack and thread"Glenn Kasten2012-08-071-5/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 5d464eb0b8cffb994a754ff108795e858a882414. It caused the wrong thread ID -1 to be passed to IAudioFlinger::createTrack(). Change-Id: Ic221d2bb4af572d3d2d752af19238c52f6728e3a
* | | | Add the ability to dynamicaly register MediaPlayer types.John Grossman2012-08-131-1/+33
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add the ability to dynamically register low level MediaPlayer factories which will be probed at setDataSource time to determine the proper MediaPlayerBase to instantiate. This change is in preparation for moving libaah_rtp out of frameworks/base and into phantasm platform directory. Change-Id: Icf8904db3ab9e3c85df6e780d5546d9988cb9076 Signed-off-by: John Grossman <johngro@google.com>
* | | Swap the order of creating IAudioTrack and threadGlenn Kasten2012-07-271-10/+5
| | | | | | | | | | | | | | | | | | Simplifies the error recovery in case IAudioTrack fails. Change-Id: I6aee41a2ac747a5689fb4836b04174e6107bf32f
* | | Clean up start() parametersGlenn Kasten2012-07-271-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | Document where int is used instead of AudioSystem::sync_event_t (probably because of a header file dependency). TrackBase::start() and RecordTrack::start() don't need default parameters. Change-Id: I82f4a4d078be900f3aa4bd926697e32f5ed68ec8
* | | effect_descriptor_t const correctnessGlenn Kasten2012-07-252-4/+4
| | | | | | | | | | | | Change-Id: Iad008f20d35a18acf500f773900164552fd0c19e
* | | AudioRecord lockingGlenn Kasten2012-07-171-14/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix race conditions for EVENT_MARKER and EVENT_NEW_POS callbacks. Marker and new position update fields are protected by lock. getSampleRate() doesn't need a lock because it reads from shared memory control block. Enforce that the parameter passed with EVENT_MARKER and EVENT_NEW_POS cannot not be changed by the callback handler, and will not change during the call by another thread. Session ID should never change; log if it does. Change-Id: Ia2c63cf1a71b10bb06c37981bd76437f83fffa91
* | | Use struct assignment instead of explicit memcpyGlenn Kasten2012-07-171-10/+3
| | | | | | | | | | | | | | | | | | for POD structs effect_descriptor_t and effect_config_t Change-Id: Ib2fc47f85fb65ed91b0abb1f87217c49b5eb571d
* | | Use audio_channel_mask_t for channel maskGlenn Kasten2012-07-172-9/+10
| | | | | | | | | | | | Change-Id: I1c1896da48983aa9f1462a4b471f910498816f60
* | | Merge "AudioRecord::stop() return void"Glenn Kasten2012-07-161-3/+1
|\ \ \
| * | | AudioRecord::stop() return voidGlenn Kasten2012-07-131-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | like AudioTrack::stop() Change-Id: Iab62f4665151345f1ad5874c97a21d1a331f0154
* | | | am 190313ec: am 65e8d62a: Merge "Fixed sample video corrupted in MediaCodec ↵Edwin Wong2012-07-131-17/+12
|\ \ \ \ | |/ / / |/| / / | |/ / | | | | | | | | | mode." into jb-dev * commit '190313ec68e81c10d200ff3c20ac152cf90760d6': Fixed sample video corrupted in MediaCodec mode.
| * | am 65e8d62a: Merge "Fixed sample video corrupted in MediaCodec mode." into ↵Edwin Wong2012-07-131-17/+12
| |\ \ | | |/ | |/| | | | | | | | | | | | | jb-dev * commit '65e8d62a5b243518795cdafa498df4a49baf6940': Fixed sample video corrupted in MediaCodec mode.
| | * Fixed sample video corrupted in MediaCodec mode.Edwin Wong2012-07-131-17/+12
| | | | | | | | | | | | | | | Change-Id: I50c5660072d40f6e297e58fd026ea04c89d6a70a related-to-bug: 6732061
* | | AudioRecord client threading cleanupGlenn Kasten2012-07-131-55/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rename ClientRecordThread to AudioRecordThread to be more similar to AudioTrack naming. Only create the thread once, and use resume() and pause() for start() and stop(). This will allow us to have a known client callback thread tid that we can pass to AudioFlinger before start(). mActive: Made mActive a bool not int. mActive is protected by mLock; volatile is meaningless. Fixed a few places where mActive was accessed without a lock: - stopped() - processAudioBuffer() These aren't used internally, so no need for _l() versions. Change-Id: I4b8a5c90f3a22d3894b344564cb1c5aef4f1fda2
* | | getMinFrameCount error handlingGlenn Kasten2012-07-132-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | Convention is for "get" APIs that directly return status_t and indirectly return a value via a pointer, to return BAD_VALUE if the pointer is NULL. Also indirectly return 0 for other errors. Change-Id: I1599f20ecb26e9723f9fb384ffbf911ff3a2ce1c
* | | Merge "Remove dead code in libmedia"Glenn Kasten2012-07-132-18/+0
|\ \ \
| * | | Remove dead code in libmediaGlenn Kasten2012-07-122-18/+0
| | | | | | | | | | | | | | | | Change-Id: I7d8201590cda29c9fa99662a4fdba222091febfe
* | | | Add tid parameter to IAudioFlinger::openRecordGlenn Kasten2012-07-122-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | Not yet implemented Change-Id: I35523fb15ad71727ecc9f4bb870f07e4b7397dc4
* | | | Simplify AudioRecord::getInputFramesLost()Glenn Kasten2012-07-121-4/+2
|/ / / | | | | | | | | | | | | | | | This also fixes a benign race in reading mActive without a lock. Change-Id: I19e953d4f275e5c266ca1ca3fece7b6c02ad1707
* | | Use audio_channel_mask_t more placesGlenn Kasten2012-07-102-14/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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 "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
* | | Use audio_channel_mask_t more consistentlyGlenn Kasten2012-07-033-20/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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 acoustics from AudioSystem::getInput()Glenn Kasten2012-06-253-9/+1
| | | | | | | | | | | | Change-Id: I29fb3ee5664c1f0ee0409c1bb2be087ecca637db
* | | Use audio_channel_mask_t in AudioRecordGlenn Kasten2012-06-251-4/+4
| | | | | | | | | | | | Change-Id: I9e1b918b2635d961604a4a9d88eb1c7179a167a7
* | | Include what you useGlenn Kasten2012-06-251-17/+7
| | | | | | | | | | | | Change-Id: I12ef9367d05dbe069c037b1b4acd6347a8cf3ece
* | | Remove AudioRecord record_flagsGlenn Kasten2012-06-221-6/+3
|/ / | | | | | | Change-Id: I021ddcc1bcb63132a4597d13e3d09db2a5f2c628
* | am 192cbbad: Fix audio track pause.Eric Laurent2012-06-141-0/+1
|\ \ | |/ | | | | | | * commit '192cbbad773979a6fe3b5a0c223356de4fc3309c': Fix audio track pause.