• 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: Audio Unit, Cocoa Interface Question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Audio Unit, Cocoa Interface Question


  • Subject: Re: Audio Unit, Cocoa Interface Question
  • From: Brian Kennedy <email@hidden>
  • Date: Mon, 4 Apr 2005 14:42:02 -0700

You want to use  [uiParam1Button state] instead.

>From the web doccumentation this...

Returns the receiver's state. The button can have two or three states.
If it has two, it returns either NSOffState (the normal or unpressed
state) or NSOnState (the alternate or pressed state). If it has three,
it returns NSOnState (the feature is in effect everywhere), NSOffState
(the feature is in effect nowhere), or NSMixedState (the feature is in
effect somewhere).

-Brian

On Apr 4, 2005 2:14 PM, mark erickson <email@hidden> wrote:
> I can't seem to get a check box to function in my audio unit plug-in if
> I use a Cocoa interface.
> Is the selected state of a check box held in the class's 'intValue'?
> If so, what have I left out below?
> If not, any hints?
> Thanks.
> Mark
>
> // *** in CocoaView.h *** //
> @interface CocoaView : NSView
> {
>      // IB Members
>      IBOutlet NSButton *                uiParam1Button;
>
>      // Other Members
>      AudioUnit                          mAU;
>      AUParameterListenerRef     mParameterListener;
> }
>
> // *** in CocoaView.m *** //
> #pragma ____ INTERFACE ACTIONS ____
> - (IBAction)iaParam1Changed:(id)sender {
>         NSAssert(       AUParameterSet(mParameterListener, sender, &parameter[0],
> [uiParam1Button intValue], 0) == noErr,
>                  @"[CocoaView iaParam1Changed:] AUParameterSet()");
> }
>
> #pragma ____ LISTENER CALLBACK DISPATCHEE ____
> - (void)_parameterListener:(void *)inObject parameter:(const
> AudioUnitParameter *)inParameter value:(Float32)inValue {
>         switch (inParameter->mParameterID) {
>                 case kParam_One:
>                         [uiParam1Button setIntValue:(int)inValue];
>                         break;
>         }
> }
>
>
>  _______________________________________________
> 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
>
>
 _______________________________________________
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: 
 >Audio Unit, Cocoa Interface Question (From: mark erickson <email@hidden>)

  • Prev by Date: Audio Unit, Cocoa Interface Question
  • Next by Date: Re: Thread count strangeness using PlayAudioFile sample code
  • Previous by thread: Audio Unit, Cocoa Interface Question
  • Next by thread: "Warning: Mac OS X MIDI Services not available"
  • Index(es):
    • Date
    • Thread