Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Application is crashing if AV1 extension is enabled #11011

Open
1 task
menscikov opened this issue Feb 23, 2023 · 5 comments
Open
1 task

Application is crashing if AV1 extension is enabled #11011

menscikov opened this issue Feb 23, 2023 · 5 comments

Comments

@menscikov
Copy link

menscikov commented Feb 23, 2023

ExoPlayer Version

2.18.3

Devices that reproduce the issue

  1. Xiaomi Redmi Note 11 Pro+ 5G
  2. Google Chromecast 4K
  3. Xiaomi Mi Box S

Devices that do not reproduce the issue

No response

Reproducible in the demo app?

Yes

Reproduction steps

  1. Build and enable AV1 extension;
  2. Set Renderer mode to DefaultRenderersFactory.EXTENSION_RENDERER_MODE_PREFER;
  3. Watch the video until the end.

Expected result

Video must stop.

Actual result

Application is crashing when video ends with Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0xa5 in tid 4654 (ExoPlayer:Playb), pid 4195 (my.app) fatal error.

Only this is available in the log:

2023-02-23 15:22:51.565  A  pid: 4195, tid: 4654, name: ExoPlayer:Playb  >>> com.my.app <<<
2023-02-23 15:22:51.565  A        #00 pc 0000000000068848  /data/app/~~6k9XQkBDbYrDWlvm8Hxukg==/com.my.app-IEHIIjZr0KcDf3VXDfJtFw==/lib/arm64/libgav1JNI.so (Java_com_google_android_exoplayer2_ext_av1_Gav1Decoder_gav1ReleaseFrame+100) (BuildId: 4f2560d8317eed9d5043c4136143f7b467bfc4d5)
2023-02-23 15:22:51.565  A        #03 pc 0000000000008092  /data/data/com.my.app/code_cache/.overlay/base.apk/classes4.dex (com.google.android.exoplayer2.ext.av1.Gav1Decoder.releaseOutputBuffer+26)
2023-02-23 15:22:51.565  A        #05 pc 0000000000007d58  /data/data/com.my.app/code_cache/.overlay/base.apk/classes4.dex (com.google.android.exoplayer2.ext.av1.Gav1Decoder$$ExternalSyntheticLambda0.releaseOutputBuffer+8)
2023-02-23 15:22:51.565  A        #07 pc 0000000000019a98  /data/data/com.my.app/code_cache/.overlay/base.apk/classes3.dex (com.google.android.exoplayer2.decoder.VideoDecoderOutputBuffer.release+4)

Media

Media link: https://woolyss.com/f/caminandes-1-llama-drama-av1-opus.webm

Bug Report

@christosts
Copy link
Contributor

I can repro on 2.18.3, and the video is not decoded properly either. Need to investigate further. Thanks for reporting this.

@menscikov
Copy link
Author

menscikov commented Feb 24, 2023

Hello @christosts, thank you.
I don't have this crash in my app old version using ExoPlayer 2.17.1. But i can't tell what AV1 (cpu_features, libgav1, abseil-cpp) were used unfortunately.

@tonihei
Copy link
Collaborator

tonihei commented Mar 2, 2023

Based on my testing, this segmentation fault in native code reproduces consistently on all ExoPlayer and libgav1 versions for particular files if the ANativeWindow rendering path is used. It does not reproduce in any configuration when GL rendering is used. Our README already recommends GL rendering because it's generally more performant and reliable. When you say it still worked in ExoPlayer 2.17.1. - could it be that you change your rendering path when upgrading? See https://github.com/google/ExoPlayer/tree/release-v2/extensions/av1#rendering-options for details.

@tonihei tonihei added need more info and removed bug labels Mar 2, 2023
@menscikov
Copy link
Author

Hello, @tonihei.
No, I use app:surface_type="surface_view" only.
And this type can't be changed on the fly as i know unfortunately.

@tonihei
Copy link
Collaborator

tonihei commented Feb 6, 2024

Sorry for the delay. I think the point above is still true that we know that the GL path is more realiable (as shown by this bug).

When you use the default player UI, would it be an option to have two different views (one with GL and one with a plain SurfaceView) and show/hide them as needed?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants