You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Previously I was using the Timer() thread to create a Volume Fade In and Fade Out effects while playing the audio and setting up the volume in it. After upgrading to the latest version of ExoPlayer now I am getting the following error message:
java.lang.IllegalStateException: Player is accessed on the wrong thread.
Current thread: 'Timer-0'
Expected thread: 'main'
I understand that ExoPlayer needs to accessed via same thread, but is there a way to create the Volume Fade In/Fade Out effect?
Thanks
The text was updated successfully, but these errors were encountered:
Yes, that's right, your need to access the player from a single thread at all times (usually the main thread). If you get signals on another thread, you can usually send a Handler message/post to the player thread to handle them there. This has always been the case, we just didn't enforce it.
We also don't support fading effects out of the box at the moment. I can mark this as an enhancement to support such effects either via Exoplayer's audio processors or via VolumeShaper.
Previously I was using the Timer() thread to create a Volume Fade In and Fade Out effects while playing the audio and setting up the volume in it. After upgrading to the latest version of ExoPlayer now I am getting the following error message:
I understand that ExoPlayer needs to accessed via same thread, but is there a way to create the Volume Fade In/Fade Out effect?
Thanks
The text was updated successfully, but these errors were encountered: