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

Media3 Exoplayer Is not pausing during Incoming Call or Other State #2131

Open
Kitta0812 opened this issue Feb 12, 2025 · 3 comments
Open

Media3 Exoplayer Is not pausing during Incoming Call or Other State #2131

Kitta0812 opened this issue Feb 12, 2025 · 3 comments

Comments

@Kitta0812
Copy link

Version
Media3 main branch

More version details
media3 version : 1.5.0

Code :

@singleton
@provides
fun provideExoPlayer(
@ApplicationContext context: Context,
trackSelector: DefaultTrackSelector,
audioAttributes: AudioAttributes,
): ExoPlayer {
return ExoPlayer.Builder(context).setTrackSelector(trackSelector)
.setWakeMode(C.WAKE_MODE_NETWORK)
.setAudioAttributes(audioAttributes, true)
.setHandleAudioBecomingNoisy(true)
.build()
}

@Singleton
@Provides
fun providesAudioAttribute(): AudioAttributes {
    return AudioAttributes.Builder().setUsage(C.USAGE_MEDIA)
        .setContentType(C.AUDIO_CONTENT_TYPE_MOVIE)
        .build()
}

I can listen Video Audio and Ringtone both, How to handle this?

@tianyif
Copy link
Contributor

tianyif commented Feb 12, 2025

Hi @Kitta0812,

Thanks for reporting! Could you please provide the information of the device model and the OS version that you used to reproduce this issue?

@Kitta0812
Copy link
Author

Hi @tianyif
I have tested in These 3 Devices and same issue in all 3
Vivo V11 Android OS 10 API 29
Redmi Note 12 OS 14 API 34
Poco X3 OS 12 API 31

@Kitta0812
Copy link
Author

Hi @tianyif
Any Update on these, else is there any Info that you required from me

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

3 participants