Questions tagged [avaudioengine]

Use this tag when your question is about the AVAudioEngine class, which is part of the AVFoundation framework.

AVAudioEngine is part of the AVFoundation framework for Apple platforms. The class provides some of the more complex audio processing functionalities within the framework, by grouping together connected audio node objects that provide functionality for creating and processing audio signals and IO.

The AVAudioEngine API can be found here.

Related tags:

449 questions
0
votes
0 answers

How to read an AVAudioFile into the same AVAudioPCMBuffer multiple times?

EDIT: I was able to prevent readIntoBuffer from returning false by adding audioFileB.framePosition = 0; at the end of my for loop. However, now it looks like bufferB only contains audio from the final readIntoBuffer call (my incomplete loop). Does…
WongWray
  • 1,685
  • 1
  • 18
  • 20
0
votes
1 answer

How can I play multiple different audio files from same AVAudioEngine? (Error: !nodeimpl->HasEngineImpl())

In my app I want to play a different audio file every time a different cell in the table view is pressed. Below is my implementation but I keep receiving the error: Terminating app due to uncaught exception 'com.apple.coreaudio.avfaudio', reason:…
D.Khan
  • 143
  • 3
  • 17
0
votes
1 answer

How to cancel or remove echo/repeated sound with AVAudioEngine?

I am using the AVAudioEngine for audio streaming. But when I speak any word into the mic, it repeats multiple times, just like echo effect. I want when I speak, it sounds only one time, not multiple times. I want to cancel the echo or extra…
Saurabh Jain
  • 1,660
  • 10
  • 28
0
votes
1 answer

Is AVAudioPlayerNode isPlaying flag set as soon as scheduleBuffer is called?

I've got two AVAudioPlayerNodes. I schedule one using scheduleBuffer. I want to cancel it before it starts but not if it has already started. How do I know if it has actually started? The isPlaying flag appears to be set as soon as it is scheduled…
Andrew Sage
  • 71
  • 2
  • 6
0
votes
1 answer

Method PlayAtTime AVAudioPlayerNode IOS Xamarin doesn't work

I want to play sound at specific time, I used Method PlayAtTime on AVAudioPlayerNode this is my code: private AVAudioUnitReverb reverb; private AVAudioEngine engine; private AVAudioFile file; private AVAudioPlayerNode audioPlayerNode; public…
0
votes
0 answers

mainMixerNode prints an error after recording

In my app I do recording and play recorded sound right away: func finishRecording(success: Bool) { audioRecorder.stop() audioRecorder = nil let audioSession = AVAudioSession.sharedInstance() do { try…
Elena Rubilova
  • 317
  • 3
  • 15
0
votes
1 answer

AVAudioEngine not posting notification in SpriteKit

I have a problem with AVAudioEngine in SpriteKit game - when plugging/unplugging of headphones the engine stops and when the next sound play the app crashes. It is a known bug (or feature?) - with a suggestion to fix it - to use notification center,…
0
votes
1 answer

Swift 3: Quickly playing sounds on AVAudioPlayerNode

I'm making a basic game and I'm trying to make hit sounds for it. I've got them to play at different pitches with help from Rhythmic Fistman, but now I have a new problem - it lags if I try playing them very quickly. This may not seem like a big…
MysteryPancake
  • 1,125
  • 1
  • 13
  • 36
0
votes
0 answers

Reduce background noise in AVAudioEngine

I'm using the below code to input voice from iPhone and playing on speaker simultaneously. But I'm getting a lot of noise feedback sound. How can that be fixed? import AVFoundation // Setup engine and node instances var engine =…
MBajaj
  • 67
  • 6
0
votes
1 answer

AVAudioInputNode permission

This might seem like a really basic question but I'm struggling to find the answer. As far as I'm aware AVAudioInputNode has been available since iOS 8 and it can be used to record from the microphone on an iPhone for example. I know previously I…
TommyBs
  • 8,497
  • 3
  • 26
  • 58
0
votes
1 answer

freeing memory in a simple avaudioengine program?

I'm wondering how to free memory in this simple program that plays a file through a buffer and then stops it. -(void)setupAudioOne { NSError *error; BOOL success = NO; _player = [[AVAudioPlayerNode alloc] init]; NSURL *hiphopOneURL =…
0
votes
1 answer

AVAudioEngine API: AVAudioUnitTimePitch too much CPU usage

I am trying to implement a simple drum pads machine application with pitch shifting filter. I am using AVAudioEngine API. There are 12 pads in app. Each pad has own class with its own AVAudioPlayerNode. When there are no other filters connected,…
jangofett
  • 59
  • 1
  • 12
0
votes
1 answer

iOS Adjust Pitch Whilst Playing via AVAudioUnitTimePitch

I’m trying to get some audio to be able to have the pitch adjusted whilst playing. I’m very new to Swift and iOS, but my initial attempt was to just change timePitchNode.pitch whilst it was playing; however, it wouldn’t update whilst playing. My…
Jacob
  • 1,204
  • 1
  • 12
  • 25
0
votes
2 answers

kAudioUnitType_MusicEffect as AVAudioUnit

I'd like to use my kAudioUnitType_MusicEffect AU in an AVAudioEngine graph. So I try to call: [AVAudioUnitMIDIInstrument instantiateWithComponentDescription:desc options:kAudioComponentInstantiation_LoadInProcess completionHandler: but that just…
Taylor
  • 4,661
  • 2
  • 24
  • 46
0
votes
2 answers

AVAudioFile can not read file from document directory

NSArray * paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); NSString * documentsDirectory = [paths objectAtIndex:0]; NSString *filePath = [NSString stringWithFormat:@"%@/audio.mp3",documentsDirectory]; NSURL…
1 2 3
29
30