-
Notifications
You must be signed in to change notification settings - Fork 94
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
Disabling "Smooth fade in/out" when starts/pauses playback #37
Comments
From what I can see, OpenSLMediaPlayerFactory#createMediaPlayer is creating the OpenSLMediaPlayer using its own getMediaPlayerOptions(). This is hard coded to always return OpenSLMediaPlayer.OPTION_USE_FADE There doesn't appear to be a way to pass through any options. If you aren't able to make changes to OpenSLMediaPlyaerFactory yourself, instantiate it as an anonymous class, override the getMediaPlayerOptions behaivor and return zero. This disables the fade on both start and pause. The same thing applies for the hybrid player. Obviously this isn't pretty, ideally there'd be a way to pass this through as a parameter into the media player factories. When I clean things up my side I plan on submitting a PR allowing this to be toggled easier.
|
thanks) it suits me more |
@martppa I second you on this. It is making screeching sound on seeking after disabling fade. |
@hunnydarapstar Hi, I fixed this issue. clone my fork and build the native library. |
@martppa okay Thanks |
@martppa can you build the library and upload it coz I am encountering errors while building from source |
Sure, here you are https://mega.nz/#!ppIG0a7R!sxRXMZSgqnhlDIopg8f_1yOwb4o-deBdaUJPMy540jw If you have any other issue let me know. |
@martppa Thanks a ton bro.. btw I have successfullt build the library from source. Cmake was not installed on my lappy, my bad..!! |
@stickyd your solution worked for me also!! @martppa Did you see any way to tune the fade in/out times? In order of tune the library i'd like also to tune the max |
@billyjoker Not sure, since the instance is created in the native side and controlled by handlers. I will try to take a look in the code and tell you if it worth to modify it. Tell ya soon. |
@martppa did you get something about this one? I'm facing another issue with Visualizer, did you notice that when nothing is sounding you have an amplitude level in the graph? If exists signal, represent a graph independent of the volume level.... it's driving me nuts... |
@billyjoker Hi, sorry for the delay, I have checked the code and there might be a way to solve it, but it might be tedious and a headache since I am not the author. |
Hi.
I need fast pause without any fade.
Can I turn it off somehow?
The text was updated successfully, but these errors were encountered: