Re: Show or Hide Parameters in Generic view dynamically?
Re: Show or Hide Parameters in Generic view dynamically?
- Subject: Re: Show or Hide Parameters in Generic view dynamically?
- From: Brian Willoughby <email@hidden>
- Date: Tue, 30 Oct 2007 23:10:15 -0700
This actually has nothing to do with UI, per se, so don't worry about
that aspect of it.
The AudioUnit design is such that notifications are used even between
different pieces of code that are not UI. Except for the kind of
polling you're doing between the kernels and the main Render method,
you generally don't poll for changes. Instead, the code that makes
changes (such as deciding to disable or hide controls) should
announce the update via a notification. Most of the time, this means
a Parameter change notification. However, if you're changing
something more than the value, such as actually disabling or enabling
a parameter, you need to notify a ParameterInfo Property change. The
new notification API has additional fields to allow you to specify
Property change notifications, as well as a few other new
notifications besides Parameter value changes.
On a related note, if you were to change the range of a Parameter,
rather than merely changing the current value, you'd also use a
Property change notification (ParameterInfo being the specific
Property that has changed).
Hope this helps. You should find specific details in the headers,
documentation, and examples.
Brian Willoughby
Sound Consulting
On Oct 30, 2007, at 22:42, Kevin Dixon wrote:
Sorry, I'm not very fluent in Mac UI...can I add a listener, ala
Java, or
how does my program "notice" that a parameter has changed?
I mean, I poll this information in my Render method, but this doesn't
seem
like the way to go.
Thanks,
-Kevin
Send a notification that the ParameterInfo property has changed. The
generic view will refresh its display
On Oct 5, 2007, at 8:12 AM, Kevin Dixon wrote:
I'm making a selectable type filter (LP/HP/BP, etc) and want certain
parameters in the generic view to become disabled or hidden when the
user changes the type. I have modified GetParameterInfo, but I
have to
close and reopen the view for the parameter's name to change from
"Bandwidth" to
"n/a", but if there was a better way to do this, I'd be glad to know.
_______________________________________________
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