Writing to the audio pipe for the remote submix is blocking, unless
the audio output pipe is in shutdown mode. The playback thread
could stay blocked on the write if the input stream has already
been closed.
The change consists in shutting down the pipe also when the input
stream gets closed. When the pipe is in this state, simulate
timing in the write operation so we don't drain the output faster
than realtime.
Bug 7424646
Change-Id: I5feb3be642b0ee7eef10dee0141308684ee9c811
Add support for querying whether there is currently a recording
underway from the specified audio source.
Bug 7314859
Change-Id: I270f27eff4dcf1cc179089859a4c690140825ad1
Support receiving a parameter that sets the remote audio submix
module in a state where the audio pipe will unblock any current
write operation and not block anymore.
Change-Id: Ia3119cd79972afff0de24187dae627855a468ebf
The way buffers are passed to JPEG encoders makes it difficult to
account for a header offset. This explains moving the header to
the end, and clarifies the required header packing.
Bug: 7108816
Change-Id: I569cd0cde37bd6fd7110fbc95d7fced9a55cff9c
The hotplug callback is non-reentrant. The display config functions
return an error if called for a disconnected display type.
Change-Id: I52d11a53f9b30a7c39e98b0a9b07eb97a3d2becd
To simplify passing compressed JPEG data between the HAL and the
camera service, add a transport header for use with JPEG streams.
Bug: 7108816
Change-Id: I91060051f59032e66eaaab3ee9f651badd1f2ac0
The reference count on the strong pointers to the audio sink and
source should be done on the object retrieved from the device
structure, not by accessing the corresponding fields, as they
can be cleared while reading or writing audio data.
Change-Id: I446a2c7bdcb0758b4013b0ad75450a15203fb9da
Change how the remote audio submix is handling piping audio
through the pipe:
- use a MonoPipe as audio sink for blocking writes,
- use a MonoPipeReader as audio source for non blocking reads,
and keep track of when recording started to align the
time at which the in_read() call should return with the
projected time of the recording duration.
Change-Id: I8b0f8c56a0486806101e272dfbf9c6d2d1c11112
Until all HAL implementations move to the new gralloc format selection
scheme, define FORMAT_ZSL for indicating ZSL streams.
Bug: 6243944
Change-Id: I90249beaaca5da80c9464eedd6aa9d3648bb56cc
Neither write nor read are blocking, but write simulates
timing by checking the clock between two writes and
computing how long the next sleep should last.
Change-Id: I495ae6d44b0cf75a24fe4b70662cfac679049c67