mirror of
https://github.com/samsonjs/media.git
synced 2026-04-27 15:07:40 +00:00
Retain decoder instance after the renderer is disabled
Issue: #2826 ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=216852679
This commit is contained in:
parent
842f622d29
commit
ba6a118998
1 changed files with 10 additions and 0 deletions
|
|
@ -558,6 +558,16 @@ public abstract class MediaCodecRenderer extends BaseRenderer {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void onDisabled() {
|
protected void onDisabled() {
|
||||||
|
if (drmSession != null || pendingDrmSession != null) {
|
||||||
|
// TODO: Do something better with this case.
|
||||||
|
onReset();
|
||||||
|
} else {
|
||||||
|
flushOrReleaseCodec();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void onReset() {
|
||||||
format = null;
|
format = null;
|
||||||
availableCodecInfos = null;
|
availableCodecInfos = null;
|
||||||
try {
|
try {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue