Questions tagged [avaudiofile]

58 questions
1
vote
3 answers

How can I use audio file as audio source in SpeechRecognition in Python?

I used speech_recognition.AudioFile in Python 3.6 , but this error was indicated: AttributeError: module 'speech_recognition' has no attribute 'AudioFile' This is my code: #!/usr/bin/env python3 import speech_recognition as sr # obtain path to…
1
vote
0 answers

Is it possible to use stream urls instead of downloading media to disk when instantiating an AVAudioPlayerNode?

We are using Amazon Cloudfront to stream audio to the iOS application. We need specific functionality that is only available on the AVAudioEngine which is why we are trying to instantiate AVAudioPlayerNode. The problem is that it appears that the…
1
vote
0 answers

Is it possible to merge two different AVAudioPlayer tracks

I have two instances of AVAudioPlayer playing two different tracks with different volume and rate (One is instrumental track and other is recording of song). I want to merge those two tracks to a single one. Is it possible to do it with…
1
vote
1 answer

How do I write AVAudioCompressedBuffer to an AAC file in iOS?

I've successfully converted the AVAudioPCMBuffers from AVAudioEngine into AVAudioCompressedBuffers with an AAC format. Now I'm trying to write those buffers to a file but don't know how to do it. AVAudioFile only accepts AVAudioPCMBuffers. Any help…
dyah
  • 63
  • 7
1
vote
0 answers

AVAudioFIle Read iOS swift Normalisation

When i try to read an audio file in swift using AVAudioFile.read() all the amplitude values are between -1 and 1.But when i read the values in python using librosa library i get different amplitude values.I think some kind of normalization is done…
1
vote
1 answer

Reversing an audio file

I'm using AVAssetReader and AVAssetWriter to reverse an audio file. However, the resulting reversed audio is very jerky. What's the best practice for reversing an audio file? Any help is much appreciated. -(void)reverseAudio:(NSURL *)videoURL…
user1752054
  • 382
  • 3
  • 17
1
vote
1 answer

how to change the pitch of recorded audio getting me following error

Terminating app due to uncaught exception 'com.apple.coreaudio.avfaudio', reason: 'required condition is false: node != nil' AVAudioFile *file=[[AVAudioFile alloc] initForReading:_recordedvoice error:nil]; AVAudioFormat…
1
vote
1 answer

Tapping microphone on AVAudioEngine input not working

I am setting up an AVAudioEngine implementation to take audio from the microphone and stream it to a websocket connection. First things first, I have tapped the microphone input and an intermediate mixer that downsamples the microphone's audio from…
Josh
  • 5,781
  • 1
  • 39
  • 67
1
vote
1 answer

session:didReceiveFile: Not Playing Audio File (iPhone to Watch)

I am having an issue with getting an audio file that I record on my iPhone to play out of my Watch speakers. Here is the code I have for sending from iPhone to Watch. - (void)sendLiveAudioRecordingToWatch { NSError *error; NSFileManager…
S. Stark
  • 169
  • 1
  • 1
  • 9
0
votes
1 answer

Get samples of audio clip in AVAudioPlayer?

Is there a property on the AVAudioPlayer class that I can use to get the samples? If not is there another class I can use to get this information? Here's what I have: var openDialog = NSOpenPanel.OpenPanel; openDialog.CanChooseFiles =…
1.21 gigawatts
  • 12,773
  • 23
  • 85
  • 187
0
votes
0 answers

I am not able to add an audio clip as an output from chatbot in rasa

I have been using rasa for over a month recently i got stuck in adding audio clip in rasa chatbot any help would be appreciated. i am using rasa version 2.0 . I have added the below code in actions.py class ActionHelloWorld(Action): def name(self)…
0
votes
1 answer

AVAudio and Offline Manual Rendering Mode - can't write buffers of higher frequencies into output file

I'm reading an input file and with the offline manual rendering mode, I want to perform amplitude modulation and to write the result to an output file. For the sake of testing, I produce pure sine waves - this works well for frequencies lower than…
0
votes
1 answer

Setting AVAudioFile `framePosition` causes crash

Whenever I set the framePosition of an AVAudioFile to something other than the current framePosition I get a crash: error - 6658 which I looked up in the Apple Docs and is: kExtAudioFileError_InvalidSeek: An attempt to write, or an offset, is…
aritroper
  • 1,549
  • 5
  • 14
  • 19
0
votes
0 answers

AVAudioFile metadata header

I am converting audio file with AVAudioConverter and then I save result to file with AVAudioFile. File is saved correct but some required metadata is missing. Here how it looks file properties that I receive RIFF (little-endian) data, WAVE audio and…
0
votes
0 answers

Creating audio file (.mp3 /.wav) from AudioQueueBufferRef

I am using ivona sdk for text to speech. This sdk works fine, but what I want is, instead of directly playing audio using AudioQueueEnqueueBuffer(audioQueue, buffer, 0, NULL) in AudioQueueEnqueueBuffer, I want to get audio file from text. It is…
Krishna Maru
  • 116
  • 13