[go: nahoru, domu]

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

Old extensions & Media3 ExoPlayer compatibility #16

Closed
NikSatyr opened this issue Dec 6, 2021 · 2 comments
Closed

Old extensions & Media3 ExoPlayer compatibility #16

NikSatyr opened this issue Dec 6, 2021 · 2 comments
Assignees
Labels

Comments

@NikSatyr
Copy link
NikSatyr commented Dec 6, 2021

We rely on some ExoPlayer extensions for audio playback within our app. These include ffmpeg, mpegh, flac & some other proprietary extensions. They have been developed & built based on com.google.android.exoplayer2. And as we suspect, these proprietary extensions will require some (unknown :)) time to be updated to use media3.

So far we decided to continue to use old com.google.android.ExoPlayer that works fine with our extensions and plug that into Media3 MediaSession by creating an adapter. That adapter would implement androidx.media3.common.Player, proxying calls to a wrapped com.google.android.ExoPlayer. However, this is going to be really cumbersome due to lots of conversions of objects.

Is there any chance that some compatibility tool will be provided or should we go with the described adapter? Or maybe there's even a better & recommended way to do this?

@icbaker
Copy link
Collaborator
icbaker commented Dec 7, 2021

And as we suspect, these proprietary extensions will require some (unknown :)) time to be updated to use media3.

media3 contains pretty much everything that exoplayer2 does - the only catch is that some classes have moved between packages. I suspect it wouldn't actually be that hard to migrate these extensions to work with media3 - it should basically just be a case of resolving compilation failures caused by classes moving around.

So far we decided to continue to use old com.google.android.ExoPlayer that works fine with our extensions and plug that into Media3 MediaSession by creating an adapter. That adapter would implement androidx.media3.common.Player, proxying calls to a wrapped com.google.android.ExoPlayer. However, this is going to be really cumbersome due to lots of conversions of objects.

Is there any chance that some compatibility tool will be provided or should we go with the described adapter?

We don't have any plans to create a tool to convert objects between exoplayer2 and media3 at runtime.

Or maybe there's even a better & recommended way to do this?

I think you're better off migrating everything to media3, rather than trying to use both exoplayer2 and media3 concurrently in the same project.

@NikSatyr
Copy link
Author
NikSatyr commented Dec 7, 2021

yep, that absolutely makes sense that migrating the extensions should be as simple as changing the package, but that should be done by our vendors. we'll try to push them, but anyway, it's our call now.

Thanks!

@NikSatyr NikSatyr closed this as completed Dec 7, 2021
@androidx androidx locked and limited conversation to collaborators Mar 4, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants