-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
[BUG]: Android TV and Android Mobile CryptoException when play m3u8 hls with DRM #3942
Comments
I don't see any issue with the usage.
I think 1 would be better. |
We tryed 1, test with media3 sample, and it works fine. Here is the code for our implementation: val activityContext = this@MainActivity
val player = ExoPlayer.Builder(activityContext).build()
val playerView = PlayerView(activityContext)
playerView.player = player
setContentView(playerView)
val videoUri =
"xxx"
val licenseUri = "xxx"
val mediaItem =
MediaItem.Builder()
.setUri(videoUri)
.setDrmConfiguration(
MediaItem.DrmConfiguration.Builder(C.WIDEVINE_UUID)
.setLicenseUri(licenseUri)
.setMultiSession(true)
.build()
)
.build()
player.setMediaItem(mediaItem)
player.prepare()
player.play() Does react-native-video do anything beyond these code to play m3u8 hls with DRM? |
If I remember well, setMultiSession(true) is not called on react native video. |
Yes, that's the problem👍 When we delete .setMultiSession(true), the same error is occured as before.
Sorry but I don't know much about how to patch react-native-video library, I'm a react native newbie😭, and it seems that when build the release apk, it will re-downloads the dependency (using expo cli), so I'm not sure if the release apk is ok even if in development mode it works |
@DidRanyeStudyToday you can try with the PR I just open. |
Sorry, I will make a clean PR when I will switch back to: #3867 |
Thank you for your support, We modified ReactExoplayerView.java in node_modules as #3947 , and now the DRM HLS can be played. Adding a prop to the https://developer.android.com/media/media3/exoplayer/media-items#protected-content Looking forward to your version update! |
I just updated this PR: #3867 |
Version
6.3.0
What platforms are you having the problem on?
Android, Android TV
System Version
Galaxy Z Flip: Android 12, One UI 4.1; ChromeCast: Android TV OS version 12
On what device are you experiencing the issue?
Real device
Architecture
New architecture with interop layer
What happened?
We tryed to play a m3u8 HLS with DRM but failed, both in Android TV and Android Mobile. The source uri + licenseServer uri can be played on shaka, so these two value is okay. the log is as follows:
on Android TV(ChromeCast):
on Android:
Reproduction
repository link
Reproduction
The text was updated successfully, but these errors were encountered: