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
47af9a68
authored
Mar 29, 2021
by
olly
Committed by
Oliver Woodman
Apr 01, 2021
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
Enable internal retry for recoverable codec exceptions
PiperOrigin-RevId: 365556167
parent
76700e9d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 additions
and
16 deletions
library/core/src/main/java/com/google/android/exoplayer2/mediacodec/MediaCodecRenderer.java
library/core/src/main/java/com/google/android/exoplayer2/mediacodec/MediaCodecRenderer.java
View file @
47af9a68
...
...
@@ -365,7 +365,6 @@ public abstract class MediaCodecRenderer extends BaseRenderer {
private
boolean
enableAsynchronousBufferQueueing
;
private
boolean
forceAsyncQueueingSynchronizationWorkaround
;
private
boolean
enableSynchronizeCodecInteractionsWithQueueing
;
private
boolean
enableRecoverableCodecExceptionRetries
;
private
boolean
enableSkipAndContinueIfSampleTooLarge
;
@Nullable
private
ExoPlaybackException
pendingPlaybackException
;
protected
DecoderCounters
decoderCounters
;
...
...
@@ -474,17 +473,6 @@ public abstract class MediaCodecRenderer extends BaseRenderer {
}
/**
* Enables internal player retries for codec exceptions if the underlying platform indicates that
* they are recoverable.
*
* <p>This method is experimental, and will be renamed or removed in a future release. It should
* only be called before the renderer is used.
*/
public
void
experimentalSetRecoverableCodecExceptionRetriesEnabled
(
boolean
enabled
)
{
enableRecoverableCodecExceptionRetries
=
enabled
;
}
/**
* Enables skipping and continuing playback from the next key frame if a sample is encountered
* that's too large to fit into one of the decoder's input buffers. When not enabled, playback
* will fail in this case.
...
...
@@ -864,10 +852,7 @@ public abstract class MediaCodecRenderer extends BaseRenderer {
}
catch
(
IllegalStateException
e
)
{
if
(
isMediaCodecException
(
e
))
{
onCodecError
(
e
);
boolean
isRecoverable
=
enableRecoverableCodecExceptionRetries
&&
Util
.
SDK_INT
>=
21
&&
isRecoverableMediaCodecExceptionV21
(
e
);
boolean
isRecoverable
=
Util
.
SDK_INT
>=
21
&&
isRecoverableMediaCodecExceptionV21
(
e
);
if
(
isRecoverable
)
{
releaseCodec
();
}
...
...
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