• 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
Creating a Discrete Parameter
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Creating a Discrete Parameter


  • Subject: Creating a Discrete Parameter
  • From: Adam Stark <email@hidden>
  • Date: Thu, 14 Aug 2008 16:48:41 +0100

Hi,

I am trying to create a parameter that takes 'discrete' values. I want it to take values between 0 and 4 at intervals of 0.25 so that the values would be...

0, 0.25, 0.5, 0.75, 1, 1.25, ..... , 3.5, 3.75, 4

I want the slider to snap to these values when I change it. I have done this before for a VST plug-in and I did something like...


newparamvalue = round(paramvalue*4)/4

where paramvalue ranges from 0 to 4. I implemented this in the SetParameter method.

The problem I have with the audio units is I don't know where to put this code. I have tried overloading the SetParameter method but that does not work. Can anyone tell me either:

a) how can I implement this in an audio unit?

or

b) is there an existing parameter profile that will let me do this?

Many Thanks in advance,

Adam
_______________________________________________
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


  • Follow-Ups:
    • Re: Creating a Discrete Parameter
      • From: William Stewart <email@hidden>
  • Prev by Date: Re: FLLR (compression ?) in AIFF file
  • Next by Date: Iphone development opportunity
  • Previous by thread: Re: Error on AUGraphInitialize
  • Next by thread: Re: Creating a Discrete Parameter
  • Index(es):
    • Date
    • Thread