Re: LAP : AU music device needs Audio & MIDI
Re: LAP : AU music device needs Audio & MIDI
- Subject: Re: LAP : AU music device needs Audio & MIDI
- From: Marc Poirier <email@hidden>
- Date: Thu, 24 Jul 2003 12:24:11 -0500 (CDT)
Hi Kent. There's a third class of AUs that might interest you:
MusicEffects.
kAudioUnitType_MusicEffect = FOUR_CHAR_CODE('aumf'),
When an AU is a MusicEffect, it's basically handled like it's essentially
an effect (takes audio input and renders audio output), but can also take
MIDI input.
In Logic, for example, you AU will show up in the effects menu (but then
won't get MIDI) and also shows up in the audio instruments menus. If you
load it as an audio instrument, it will get MIDI input, and you can route
audio input into it via the sidechain menu in the plugin window.
However, if your AU is essentially an instrument (I guess it can be a
matter of taste in some cases, how you classify it, so I don't know how
you'd classify your plugin), then you should still be able to make it a
MusicDevice and receive audio input. There's nothing about MusicDevices
that says that they can't have audio input. In Logic, you should get a
sidechain menu if you make an MD that requires audio input. If this does
not occur (I haven't tried myself, so I'm not sure), then I would get in
touch with Emagic about getting them to fix the problem.
Doing the thing with your resources both pointing to the same binary entry
point should be fine. It's even pretty easy to figure out which AU was
loaded at run-time. If you're using AUBase, you can do this:
ComponentDescription desc;
OSErr error = GetComponentInfo((Component)GetComponentInstance(), &desc, NULL, NULL, NULL);
if (error == noErr)
{
if (desc.componentType == kAudioUnitType_MusicEffect)
DoSomething();
else if (desc.componentType == kAudioUnitType_MusicDevice)
DoSomethingElse();
}
Marc
On Thu, 24 Jul 2003, kent wrote:
>
Hello. I think this is maybe a Logic Audio specific problem. My plugin
>
needs both MIDI input and Audio input. when I register her as a
>
aumu (music device) then she is pluggable in the AudioInstrument input
>
slot of logic. however I cannot manage to route audio (even through
>
the side-chain) to my plugin. and when I register her as a aufx (audio
>
effect) then I cannot receive MIDI data.
>
>
so in my .r file I make 'thng' resources for BOTH aumu and aufx and
>
have them both point to my plug, so that I can then at least plug the
>
fx version onto an audio track and do processing without MIDI and also
>
plug into an instrument track and synthesize from MIDI, but THEN I get
>
the really exciting behaviour that when logic saves and then later
>
restores my plug logic always thinks I'm an aufx, and doesn't
>
instantiate me as an aumu when it should. I was truly hoping that I
>
would not have to build two different discrete binaries, one for fx and
>
one for mu, especially since in the end neither of these does exactly
>
what I want them to do (which is receive audio and midi
>
simultaneously). Is there perhaps something simply screwed up with
>
logic audio 6.1 in regards to side-chain and audio units? or am I just
>
missing something.
>
>
thanks in advance for helping me.
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.