Skip to content

Conversation

@fivecar
Copy link
Contributor

@fivecar fivecar commented Jul 31, 2023

This is an RFC for supporting the fading in of audio when you play(). The idea would be to support AVPlayerWrapper.rampSecs, which, if set to non-zero, fades audio in every time you play. The broader proposal would be to expose this through RNTP at some point so that people can implement players where audio ramps in whenever Play is hit.

Eager to hear feedback on this. Alternatives to this include having clients just setTimeout themselves, manually calling setVolume a bunch of times with incrementally-increasing values, but: a) a native implementation ramps volume much more smoothly, and b) this makes it effortless to create players that always ramp sound in.

This is an RFC for supporting the idea of fading audio in when you play. The idea would be to support AVPlayerWrapper.rampSecs, which, if set to non-zero, fades audio in every time you play. The broader proposal would be to expose this through RNTP at some point so that people can implement players where audio ramps in whenever Play is hit.

Eager to hear feedback on this. Alternatives to this include having clients just `setTimeout` themselves, manually calling `setVolume` a bunch of times with incrementally-increasing values, but: a) a native implementation ramps volume much more smoothly, and b) this makes it effortless to create players that always ramp sound in.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant