• 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: Question about AudioUnits, Cocoa views, and getting info at init time
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Question about AudioUnits, Cocoa views, and getting info at init time


  • Subject: Re: Question about AudioUnits, Cocoa views, and getting info at init time
  • From: "Sophia Poirier [dfx]" <email@hidden>
  • Date: Tue, 29 Sep 2009 15:26:09 -0400

I'm not completely clear on your question, but is it the situation that you are asking about an AU that you are developing, and you are asking about how your AU's GUI component can query the number of channels? If so, then yes, getting the StreamFormat property is the way to do it. Presuming that your ... indicate other proper arguments, then that should be working. But if not, then debug your AU and figure out why it is giving 0 for the number of channels.

If your AU GUI differs depending on the channel count, then you need to install a property listener on the StreamFormat property and redo your GUI accordingly when the channel count changes. I have an open source AU called RMS Buddy that does this that you could take a look at as an example if you care to:
http://destroyfx.org/extras/#rmsbuddy


- Sophia



On Sep 28, 2009, at 7:28 PM, Walt wrote:

I'm having a problem with determining an audiounit's channel count
from its GUI at init time.

Specifically, the plug-in supports a number of different channel
counts (stereo + surround), but needs to do different things depending
on how it is instantiated - including build a different gui. The
stereo case looks different than the 5.1 case, as does the 6.1, etc.

Everything I've tried* tells me input and output channel counts are 0.
This tells me I'm not looking in the right place.

Any ideas?

Thanks,


Walt ---- I've tried calling AudioUnitGetProperty(...kAudioUnitProperty_StreamFormat...) - it returns a structure which suggests 0 input channels and 0 output channels

I've tried adding a property to the plug-in which calls through to
AUEffectBase::GetNumberOfChannels(), again returning 0 output
channels. I tried the same on the input side (GetInput(0)-
GetStreamFormat().mChannelsPerFrame) and this once again yielded 0.

_______________________________________________ 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
  • Prev by Date: AU missing on Snow leopard?
  • Next by Date: Getting PCM stream from MP3 hardware assisted decoder
  • Previous by thread: Re: Question about AudioUnits, Cocoa views, and getting info at init time
  • Next by thread: AU missing on Snow leopard?
  • Index(es):
    • Date
    • Thread