objective c - IOS Audio units -


i trying implement low pass filter in core audio on ios when use code below error generated stating "the operation not completed", undescriptive of problem. , can see operation illegal.

can me this? or refer me place decent documentation core audio because apples documentation unhelpful indeed.

result = augraphnodeinfo(processinggraph, lowpassnode, null, &lowpassunit); if(result != noerr) {     [self printerrormessage: @"augraphnodeinfo" withstatus: result];     return; }  int bytesize = sizeof(audiounitsampletype); audiostreambasicdescription streamformat; streamformat.mformatid          = kaudioformatlinearpcm; streamformat.mformatflags       = kaudioformatflagsaudiounitcanonical; streamformat.mbytesperpacket    = bytesize; streamformat.mframesperpacket   = 1; streamformat.mbytesperframe     = bytesize; streamformat.mchannelsperframe  = 1; streamformat.mbitsperchannel    = 8 * bytesize; streamformat.msamplerate        = graphsamplerate;  nslog (@"setting stream format lowpass unit input bus"); result = audiounitsetproperty(lowpassunit,                               kaudiounitproperty_streamformat,                               kaudiounitscope_input,                               0,                               &streamformat,                               sizeof (audiostreambasicdescription)); if (noerr != result) {     nslog(@"%@", [nserror errorwithdomain:nsosstatuserrordomain code:result userinfo:nil]);     return; } 

this isn't direct answer question, should really use novocaine. setting audiounits hand in ios exercise in frustration, , shouldn't directly more unless doing special things au graph. simple applying lopass filter given signal, framework more reliable.


Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -