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

Commit 7966b441 authored by Andy Hung's avatar Andy Hung Committed by Android (Google) Code Review
Browse files

Merge "AudioTrack: Fix extended timestamp offset" into oc-mr1-dev

parents cc840346 c4e60eb1
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -615,7 +615,8 @@ status_t AudioTrack::start()
                            + mStartEts.mPosition[ExtendedTimestamp::LOCATION_SERVER]),
                    (long long)mStartEts.mFlushed,
                    (long long)mFramesWritten);
            mFramesWrittenServerOffset = -mStartEts.mPosition[ExtendedTimestamp::LOCATION_SERVER];
            // mStartEts is already adjusted by mFramesWrittenServerOffset, so we delta adjust.
            mFramesWrittenServerOffset -= mStartEts.mPosition[ExtendedTimestamp::LOCATION_SERVER];
        }
        mFramesWritten = 0;
        mProxy->clearTimestamp(); // need new server push for valid timestamp