Skip to content

Commit

Permalink
Merge pull request #1 from BrightcoveOS/updateDurationFix
Browse files Browse the repository at this point in the history
Modified updateDurationUs() to also filter out TrackRenderers with a
  • Loading branch information
pajato1 committed Oct 23, 2015
2 parents 54fed33 + 8f2103d commit 5904b22
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 114 deletions.
33 changes: 0 additions & 33 deletions build.gradle~

This file was deleted.

80 changes: 0 additions & 80 deletions library/build.gradle~

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,10 @@ private void updateDurationUs() {
long durationUs = 0;
for (int i = 0; i < renderers.length; i++) {
TrackRenderer renderer = renderers[i];
if (rendererEnabledFlags[i] && renderer.getState() != TrackRenderer.STATE_UNPREPARED && renderer.getState() != TrackRenderer.STATE_RELEASED ) {
if (rendererEnabledFlags[i]
&& renderer.getState() != TrackRenderer.STATE_IGNORE
&& renderer.getState() != TrackRenderer.STATE_UNPREPARED
&& renderer.getState() != TrackRenderer.STATE_RELEASED ) {
if (durationUs == TrackRenderer.UNKNOWN_TIME_US) {
// We've already encountered a track for which the duration is unknown, so the media
// duration is unknown regardless of the duration of this track.
Expand Down

0 comments on commit 5904b22

Please sign in to comment.