Closed scottkz closed 2 years ago
Does using a video that is https solve it?
Does using a video that is https solve it?
No it does not. I actually tried it first with my Vimeo private links which are all https, and then that lead me to testing. I tried the big bunny url but simply forgot the "s" on http. It plays the audio, and progresses, just to a black screen either way.
Edit:
It does work on Android emulators running API 28 and lower. So I'm wondering if it's just an emulator issue somehow.
Using an emulator with API 28 and Android 9.0 (instead of API 30 and Android 11.0) solved the problem for me as well.
Using an emulator with API 28 and Android 9.0 (instead of API 30 and Android 11.0) solved the problem for me as well.
Glad to see you had the same experience, well not glad, but at least we can say it's either an issue with react-native-video on newer API's or emulator resource issues with newer API's. My only concern is I don't have a physical Android device and didn't want to leave it to chance that a physical device would just work. Can anyone confirm that react-native-video is also having issue on physical devices running API 29 or higher?
I can confirm this is an issue on physical devices. My Pixel 4 XL on Android 11 does not play videos, but every emulator I use works just fine.
EDIT: Oddly enough, when my Pixel 4 XL is connected to the metro server in dev mode videos load fine. Any help here is appreciated.
I can confirm this is an issue on physical devices. My Pixel 4 XL on Android 11 does not play videos, but every emulator I use works just fine.
EDIT: Oddly enough, when my Pixel 4 XL is connected to the metro server in dev mode videos load fine. Any help here is appreciated.
Thank you for the info. I'm glad I didn't leave it to chance and just used Vimeo's player API instead. It's super frustrating, and a little mind boggling that this doesn't work correctly on the most recent versions of the Android SDK (29,30 and presumably 31).
I much rather use this library on Android devices just like I do on the iOS side, but like with most things, the iOS is running much smoother. I guess all we can do is hope the devs see this.
Also, are the emulators you're using running Android 10 or higher. I'm curious how you are getting that to display video and not just audio as that was how I found this issue. If possible could you share your grade files showing how you setup this library and a super basic example of how you have it working? Just to try to see if I can spot a difference somewhere. Thanks.
Same thing here ((. any solution yet?
same issue for me
Anyone get this figured out by chance?
This solution seems to be the only one that works https://github.com/yqritc/Android-ScalableVideoView/issues/52#issuecomment-1014817588
Has it been determined that we are SoL on newer versions of Android and need to find a different solution?
I think your problem is that while your implementation is basic, it certainly is not official code, and the problem lies most likely in your logic or an bug in one of the optional onLoadStart, ect... prop . I've tested with a more basic implementation that works fine on newer APIs using physical devices. Could also be the video you're loading in.
@UberMC I thought of that so I tried the sample file https://sample-videos.com/video123/mp4/720/big_buck_bunny_720p_10mb.mp4 (since http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4 appears to be a dead link) and got the same results.
Bug
Using a basic implementation of the player using react-native, I have tried with both native controls and as shown here custom controls, the video will not produce video playback, but only audio playback on an Android emulator running API 29 or 30. I have tried all different versions of both react-native and react-native-video to no avail. I have tried with and without linking and using the README's guide to >=5.0 setup on Android. Nothing seems to be working.
Now, it does work great on iOS and any Android emulator running API 28 and 27 as that's as far back as I've tested so far. I've tried searching for this issue, but can't find it anywhere so that leads me to believe it's something I'm doing otherwise I'd expect it to be a huge deal for this library. Please let me know if I'm just missing something simple here. Thanks!
Platform
Which player are you experiencing the problem on:
Environment info
React native info output:
Library version: 5.1.1 / 5.0.1 / 4.2.0 / 3.2.0
Steps To Reproduce
Expected behaviour
Reproducible sample code
VideoPlayer.js
logact (debug mode) outputs:
not sure if these may help
Link to the repository: https://github.com/scottkatzelnick/rn-video-demo
Video sample
Google Drive link to video running on an Android Emulator (Pixel 3a API 30, rn v65.1, library version 5.1.1): https://drive.google.com/file/d/1GneDCXCll1P_6C6Mt9EUIV7J5P-9SwBd/view?usp=sharing