Questions tagged [react-native-sound]

79 questions
0
votes
0 answers

What is the simplest way to create a music player using react-native-sounds with play & pause toggle controls in same button?

I wanted to create a music player using react-native-sounds but and it was playing music flawless but the issue wast it was not stoping when i press the button, btw the button of play & pause is same.I also want it to pause when another track is…
0
votes
0 answers

Audio not playing when a random url path is passed from REST API

I have a util function defined in soundLoader.js that will play the audio. And I have a react-native component I called the util function and passed the url to play the audio. I get the url by the id from currently clicked button using rest api, and…
Samaritan
  • 55
  • 7
0
votes
0 answers

React Native Sound: AAC files are not played on IOS (OSStatus error 2003334207.)

I'm currently trying to play .aac audio files using the react-native-sound library. Same file works on Android with the same code. Additionally I've also tried the converted version of the audio file to .wav and this also works. Any idea what I…
Bruno
  • 894
  • 11
  • 32
0
votes
1 answer

Sequentially play an array of sounds using react-native-sound

I am using the function below to attempt to play the array (a,b,c are all Sound instances initialised beforehand) of sounds (notes) sequentially (a is played and ends, then b is played and ends etc.). However instead of playing each sound one after…
0
votes
0 answers

React-native-sound import crashes the App

I'm not new to React, but I'm new to React Native. I've jumped very optimistic to it, but for now it looks like one big fat buggy thing. I wanted to build just simple metronome, but spent hours dealing with bugs. And here's one more.…
meAndrew
  • 144
  • 1
  • 13
0
votes
1 answer

What is the correct way to use react-native-sound?

When using the RNSound library, I ran into a problem - I can't pause the sound. initialize : Sound.setCategory("Playback"); let whoosh = new Sound("complite.mp3", Sound.MAIN_BUNDLE, (error) => { if (error) { console.log("failed to load the sound",…
kentavr16
  • 3
  • 4
0
votes
0 answers

Playing an audio file with react-native-sound-player

I just started using React Native and am working on a second trial to play an audio file in a test app. But it fails. Here is what I do: First setting the app, on the terminal. $ expo init TestAudioRNSP $ cd TestAudioRNSP $ npm install --save…
Michel
  • 10,303
  • 17
  • 82
  • 179
0
votes
0 answers

React Native Sound - after speed up audio and pausing, the time goes back

I have weird problem with react-native-sound library. I added possibility to speed up audio and it works while changing speed when audio is playing. When I press stop button and then start, time goes back on my slider which cause that audio is…
Frendom
  • 508
  • 6
  • 24
0
votes
1 answer

react-native sound not working after a while

I'm using 50 different sound files. it works normally but on my 14th or 15th try it no longer plays the audio files. (I am using android device) const animalSound = new Sound( selectedAnimals.soundUrl ||"snake.mp3", null, error => { if (error)…
spaceWalker
  • 139
  • 1
  • 10
0
votes
0 answers

React Native Sound change speed time

I'm using react-native-sound library to play audio in my app. I would like to add option to control speed time of listening. in my AudioPlayer component I have: const [music, setMusic] = useState(null) const [isPlaying, setPlaying] =…
Frendom
  • 508
  • 6
  • 24
0
votes
1 answer

issue with react native local notification and play sound

I'm creating react native app on googleplay im using react native pushNotification and react-native-sound everything is work proper till the last update when I upload bundle on googleplay notification sound play with the sound that I use in one of…
0
votes
1 answer

react native sound Not working on Windows: Cannot read property 'IsAndroid' of undefined

I'm working on project for android and windows using react native CLI and I want to play sound when the user clicks a butto. For that, I've used react-native-sound as the most famous library to play sounds on react native and the it supports windows…
0
votes
0 answers

React Native audio change pitch sound audio

I'm looking for solution in react-native to change audio file pitch on iOS, https://github.com/zmxv/react-native-sound look's like using AVAudioPlayer and that's why it's not supported for changing pitch on iOS. so my main question is there any iOS…
0
votes
1 answer

Measuring decibels in react native expo

I am trying to build a range timer. Which essentially starts a timer and stops it when a shot has been fired. For this I thought I would measure decibels and when it spikes I stop the timer. Now I have had a look around everywhere and can't seem to…
0
votes
1 answer

iOS : Can't play sound when the application is in the background

With react-native-sound and react-native-background-timer, I want to play a sound after 10 seconds delay. Here is my very simple code : import BackgroundTimer from 'react-native-background-timer' import Sound from…
Gaylord.P
  • 1,539
  • 2
  • 24
  • 54