• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: getting host tempo in an Audio Unit
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: getting host tempo in an Audio Unit


  • Subject: Re: getting host tempo in an Audio Unit
  • From: Artemiy Pavlov <email@hidden>
  • Date: Sun, 27 Aug 2006 14:32:48 +0300

Hello Stiwi!

Thank you *so* much for the help! I really thought it should be a little more simple, and what you suggested with your last mail works perfectly!

But now may I ask another simple question?

As I got the tempo value from the host (stored in the HostTempo variable), I am trying to update my plugin's "Tempo" slider (the kTempo parameter) with this value:

mAudioUnit->SetParameter( kTempo, HostTempo );

But this doesn't work... What is the right way to update the plugin view? I have a generic view by the way, no custom UI.


Thanks again Stiwi, I really appreciate and value your help.


With best wishes,

Artemiy.


On 27 Aug 2006, at 11:32 AM, stiwi wrote:

Hi Artemiy,

sorry if i explained it the wrong way around.

Take a look at the AUKernelBase.h file. The kernel gets a pointer to the parent class and stores it in
a protected member variable named mAudioUnit. If you just add something like this in your
kernels process() call everything should work .


	Float64		bpm;
	OSStatus	err	= mAudioUnit->CallHostBeatAndTempo(NULL, &bpm);

	if (err == noErr)
		printf("MyKernel::Process %f\n", bpm);

As an example add this to the FilterDemo.cpp Process() call and take a look at the console output.

Cheers,
stiwi

_______________________________________________ Do not post admin requests to the list. They will be ignored. Coreaudio-api mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >getting host tempo in an Audio Unit (From: Artemiy Pavlov <email@hidden>)
 >Re: getting host tempo in an Audio Unit (From: stiwi <email@hidden>)
 >Re: getting host tempo in an Audio Unit (From: Artemiy Pavlov <email@hidden>)
 >Re: getting host tempo in an Audio Unit (From: stiwi <email@hidden>)
 >Re: getting host tempo in an Audio Unit (From: Artemiy Pavlov <email@hidden>)
 >Re: getting host tempo in an Audio Unit (From: stiwi <email@hidden>)

  • Prev by Date: Re: getting host tempo in an Audio Unit
  • Next by Date: Format Converter problem
  • Previous by thread: Re: getting host tempo in an Audio Unit
  • Next by thread: MIDISourceCreate and MIDIReceived
  • Index(es):
    • Date
    • Thread