开发者

AudioUnit: access ComponentKernel properties from CocoaView

I would like to access my AudioUnit Component Kernel members from an action method defined in the cocoa view of my AudioUnit Component :

开发者_开发技巧- (IBAction)iaParam1Changed:(id)sender {
    float floatValue = [sender floatValue];
    NSAssert(AUParameterSet(mParameterListener, sender, &mParameter[0], (Float32)floatValue, 0) == noErr, @"[MyAudioUnit_CocoaView iaParam1Changed:] AUParameterSet()");
    if (sender == uiParam1Slider) {
        [uiParam1TextField setFloatValue:floatValue];
    } else {
        [uiParam1Slider setFloatValue:floatValue];
    }
}

(For instance, interact with stats computed on the signal...). But I don't know how to use the AudioUnit mAU member of the Cocoa View to get the Kernel (and then its members)... How would you do that? (Maybe i'm not supposed to do that?) Thanks.


  • Define an AudioUnit custom property
  • Access it from the cocoa view using AudioUnitGetProperty
  • Reimplement the AUEffectBase::GetProperty method
  • From GetProperty, access the kernels using the GetKernel(...) method
  • Enjoy some tee
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜