AURemoteIO :: IOThread EXC_BAD_ACCESS

时间:2016-04-07 09:41:47

标签: ios objective-c audiounit

我正在使用AudioGraph。mvn gwt:debug是一个回调函数。

eqRenderInput

static OSStatus eqRenderInput(void *inRefCon, AudioUnitRenderActionFlags *ioActionFlags, const AudioTimeStamp *inTimeStamp, UInt32 inBusNumber, UInt32 inNumberFrames, AudioBufferList *ioData) { @autoreleasepool { NSLog(@"--method = %s--current thread:%@",__func__,[NSThread currentThread]); MyAudioController *mycon = (__bridge MyAudioController *)inRefCon; AudioUnit mixUNIT = mycon->mixUnit; AudioUnitRender(mixUNIT, ioActionFlags, inTimeStamp, inBusNumber, inNumberFrames, ioData); int bufferCount = ioData->mNumberBuffers; NSLog(@"current thread:%@----bufferCount=%d",[NSThread currentThread],bufferCount); // Fill the provided AudioBufferList with the data from the AudioBufferList output by the audio data output for (int bufferIndex = 0; bufferIndex < bufferCount; bufferIndex++) { NSData *tmpData = [NSData dataWithBytes:ioData->mBuffers[bufferIndex].mData length:ioData->mBuffers[bufferIndex].mDataByteSize]; [mycon->mixMArray addObject:tmpData]; // this line carsh NSLog(@"mchannel = %d---bufferIndex = %d",ioData->mBuffers[bufferIndex].mNumberChannels,bufferIndex); } } } 班级为mixMArrayNSMutableArray此次线路崩溃,  错误消息为[mycon->mixMArray addObject:tmpData];

0 个答案:

没有答案