[go: nahoru, domu]

Skip to content

Commit

Permalink
Fix issue with updating the last rebuffer time
Browse files Browse the repository at this point in the history
The last rebuffer time was being updated erroneously, even in the absence of rebuffering events, resulting in incorrect `bs` (buffer starvation) key in CMCD.

Issue: #1124
PiperOrigin-RevId: 629731796
  • Loading branch information
rohitjoins authored and Copybara-Service committed May 1, 2024
1 parent e25bd07 commit feb5125
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions RELEASENOTES.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
* Add `ExoPlayer.setPriority` (and `Builder.setPriority`) to define the
priority value used in `PriorityTaskManager` and for MediaCodec
importance from API 35.
* Fix issue with updating the last rebuffer time which resulted in
incorrect `bs` (buffer starvation) key in CMCD
([#1124](https://github.com/androidx/media/issues/1124)).
* Transformer:
* Work around a decoder bug where the number of audio channels was capped
at stereo when handling PCM input.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3019,7 +3019,7 @@ private static boolean isUsingPlaceholderPeriod(
private void updateRebufferingState(boolean isRebuffering, boolean resetLastRebufferRealtimeMs) {
this.isRebuffering = isRebuffering;
this.lastRebufferRealtimeMs =
resetLastRebufferRealtimeMs ? C.TIME_UNSET : clock.elapsedRealtime();
isRebuffering && !resetLastRebufferRealtimeMs ? clock.elapsedRealtime() : C.TIME_UNSET;
}

/**
Expand Down

0 comments on commit feb5125

Please sign in to comment.