Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 0f51fd07 authored by Dean Wheatley's avatar Dean Wheatley
Browse files

Fix direct/offload AudoTrack playback head position on flush & re-use

AudioTrack: If the direct/offload track is flushed or stopped, the
server render position may still be returning stale values because the
HAL flush may not have executed yet. To honor the position reset on
flush contract, return 0 when in flushed/stopped state consistently for
all track types (direct and non-direct).

DirectOutputThread: if previous track flush is pending while adding a
new track for OffloadThread, issue the flush, even if the sessionId is the
same, because the client will be expecting a reset frame count.

Test: AudioTrackSurroundTest#testAC3PositionAfterFlushReleaseNewTrack
      passes reliably on AC3 MSD HAL enabled Cuttlefish
Bug: 243899467
Change-Id: Ia2e8ca574a3c8063d14df9d86d3c6ea5c44ba3fb
parent d722067c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment