| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When a capture thread was closed, the effects attached to this thread
were left dangling and the associated effect chain destroyed.
When their last client was disconnected, the effects were not released
properly from the effect library because the destruction process could
not be completed without the effect being attached to a thread.
A similar problem prevented a RecordTrack to be properly released if
its client was destroyed after the capture thread.
The fix consists in allowing the effect or record track to be properly
released even if its parent thread cannot be promoted.
Also save any effect chain still present on a closed capture thread
in case a new client wants to reuse the effects on the same session later.
Bug: 17110064.
Change-Id: I5cd644daa357afd1f3548f9bcb28e6152d95fdb8
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add support for audio device connections between different audio
hw modules.
The patch is performed by creating a bridge between the playback
thread connected to the sink device and the record thread connected
to the source device using a pair of specialized PlaybackTrack and
RecordTrack.
- Added PatchTrack and PatchRecord classes.
- Added TrackBase type to indicate more clearly the track behavior.
- A TrackBase can allocate the buffer or reuse an existing one.
- Factored some code in openOutput() and openInput() for internal use
by PatchPanel.
Bug: 14815883.
Change-Id: Ib9515fcda864610458a4bc81fa8f59096ff4d7db
|
|
|
|
| |
Change-Id: Ib9ac170f8e8b7746b3588157a56cbee3b753a1cb
|
|
|
|
| |
Change-Id: I6bd48292310be4e05758a11f617f50585904422d
|
|
|
|
|
|
|
|
| |
openRecord() now explicitly returns the control block and data buffer
as separate IMemory references. If the IMemory for data buffer
is 0, this means it immediately follows the control block.
Change-Id: Ic098f88f0e037f8fbe30006689e18cacacf09d06
|
|
|
|
|
|
| |
Supports multiple clients both at native sample rate and with resampling.
Change-Id: Icea55b4fd30751761b7debaa3ce016c79e712d8d
|
|
|
|
|
|
|
| |
Set a work source for the playback wakelock, so that playback is
counted against the requesting app instead of the media server.
Change-Id: I7329f88a288a95a582a78005a1c3d16a5a611e31
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Outside callers now use initCheck() to determine whether a TrackBase
has been created successfully, instead of relying on internal knowledge.
Previously, callers needed to know that a TrackBase was only valid if it's
getCbk() != 0. For a Track (playback), they needed to know to also check
the track's name (track index). Now, outsiders can just call initCheck().
Other changes:
- Return a 0 reference if track creation fails
- Remove a dead line of code in AudioFlinger::openRecord
Change-Id: If374924a3f6fd27906f625aa83dd0a1e3f506e00
|
|
|
|
| |
Change-Id: Ic39c7baa9538080bfec114bf18ff9b9986c93fed
|
|
|
|
|
|
| |
mChannelCount was 8-, 16-, or 32-bits
Change-Id: I2cc2fedf3e33144e5c8bbd9894763282d9217f63
|
|
|
|
| |
Change-Id: I507c6109d66000bb30933ca23b912a1316f55e5e
|
|
|
|
| |
Change-Id: I6347096f066b8b19451c6472db7b0671f0cf7702
|
|\ |
|
| |
| |
| |
| | |
Change-Id: I38100b7e28a12d7af8cb40ae3f4d9cb4a0ebe701
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Added specialized playback thread class for offload playback,
derived from directoutput thread.
This thread type handles specific state transitions for offloaded
tracks and offloading commands (pause/resume/drain/flush..) to audio HAL.
As opposed to other threads, does not go to standby if the track is paused.
- Added support for asynchronous write and drain operations at audio HAL.
Use a thread to handle async callback events from HAL: this avoids locking
playback thread mutex when executing the callback and cause deadlocks when
calling audio HAL functions with the playback thread mutex locked.
- Better accouting for track activity: call start/stop and release Output
methods in audio policy manager when tracks are actually added and removed
from the active tracks list.
Added a command thread in audio policy service to handle stop/release commands
asynchronously and avoid deadlocks with playback thread.
- Track terminated status is not a state anymore. This condition is othogonal
to state to permitted state transitions while terminated.
Change-Id: Id157f4b3277620568d8eace7535d9186602564de
|
|
|
|
|
|
|
|
| |
Main differences between old and new control block:
- removes the mutex, which was a potential source of priority inversion
- circular indices into shared buffer, which is now always a power-of-2 size
Change-Id: I4e9b7fa99858b488ac98a441fa70e31dbba1b865
|
|
|
|
|
|
|
|
|
|
| |
Abbreviation framesReady to fRdy for new systrace.
Put inline const on one line.
Use local copy of mState in state.
Improve logging.
Line length 100.
Change-Id: I8201c3ce0e53fd464fd33d02544e52c342d40b68
|
|
|
|
|
|
|
|
|
|
| |
Implement rotation to reduce long-term storage use.
Implement optional per-track tee.
Dynamically enable at runtime based on property, instead of at compile-time.
Dynamic frame count not yet implemented.
Bug: 8223560
Change-Id: I3706443c6ec0cb0c6656dc288715a02ad5fea63a
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The proxy object will eventually be the only code that understands the
details of the control block. This should make it easier to change the
control block in the future.
Initial set of control block fields that are isolated:
- sample rate
- send level
- volume
Prepare for streaming/static separation by adding a union to the control
block for the new fields.
Fix bug in handling of max sample rate on a track. It was only checking
at re-configuration, not at each mix.
Simplify OutputTrack::obtainBuffer.
Change-Id: I2249f9d04f73a911a922ad1d7f6197292c74cd92
|
|
Audioflinger.cpp and Audioflinger.h files must be split to
improve readability and maintainability.
This CL splits the files as follows:
AudioFlinger.cpp split into:
- AudioFlinger.cpp: implementation of IAudioflinger interface and global methods
- AFThreads.cpp: implementation of ThreadBase, PlaybackThread, MixerThread,
DuplicatingThread, DirectOutputThread and RecordThread.
- AFTracks.cpp: implementation of TrackBase, Track, TimedTrack, OutputTrack,
RecordTrack, TrackHandle and RecordHandle.
- AFEffects.cpp: implementation of EffectModule, EffectChain and EffectHandle.
AudioFlinger.h is modified by inline inclusion of header files containing
the declaration of complex inner classes:
- AFThreads.h: ThreadBase, PlaybackThread, MixerThread, DuplicatingThread,
DirectOutputThread and RecordThread
- AFEffects.h: EffectModule, EffectChain and EffectHandle
AFThreads.h includes the follownig headers inline:
- AFTrackBase.h: TrackBase
- AFPlaybackTracks: Track, TimedTrack, OutputTrack
- AFRecordTracks: RecordTrack
Change-Id: I512ebc3a51813ab7a4afccc9a538b18125165c4c
|