Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
SDK
/
exoplayer
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
9bcc00f3
authored
Sep 10, 2015
by
Oliver Woodman
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
Fix reported buffered position for HLS across format switches.
parent
a7ba393d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
library/src/main/java/com/google/android/exoplayer/hls/HlsSampleSource.java
library/src/main/java/com/google/android/exoplayer/hls/HlsSampleSource.java
View file @
9bcc00f3
...
@@ -353,6 +353,12 @@ public final class HlsSampleSource implements SampleSource, SampleSourceReader,
...
@@ -353,6 +353,12 @@ public final class HlsSampleSource implements SampleSource, SampleSourceReader,
return
TrackRenderer
.
END_OF_TRACK_US
;
return
TrackRenderer
.
END_OF_TRACK_US
;
}
else
{
}
else
{
long
largestParsedTimestampUs
=
extractors
.
getLast
().
getLargestParsedTimestampUs
();
long
largestParsedTimestampUs
=
extractors
.
getLast
().
getLargestParsedTimestampUs
();
if
(
extractors
.
size
()
>
1
)
{
// When adapting from one format to the next, the penultimate extractor may have the largest
// parsed timestamp (e.g. if the last extractor hasn't parsed any timestamps yet).
largestParsedTimestampUs
=
Math
.
max
(
largestParsedTimestampUs
,
extractors
.
get
(
extractors
.
size
()
-
2
).
getLargestParsedTimestampUs
());
}
return
largestParsedTimestampUs
==
Long
.
MIN_VALUE
?
downstreamPositionUs
return
largestParsedTimestampUs
==
Long
.
MIN_VALUE
?
downstreamPositionUs
:
largestParsedTimestampUs
;
:
largestParsedTimestampUs
;
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment