• 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: logic problem. adding sine wave pattern to dynamic float
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: logic problem. adding sine wave pattern to dynamic float


  • Subject: Re: logic problem. adding sine wave pattern to dynamic float
  • From: Jens Alfke <email@hidden>
  • Date: Fri, 5 Feb 2010 08:56:01 -0800

On Feb 5, 2010, at 6:02 AM, Chunk 1978 wrote:

> however, if you look at those numbers they are not much of a sine
> wave.  the reason, as far as i can see, is that self.pitch is adding
> itself along with the sine wave increments.

Right. You have to remember the base pitch and add the sin value to that:

pitch = basePitch + vibratoDepth*sin(vibratoPhase)

You should take this to stackoverflow.com or some other general programming Q&A forum, since it's off topic for this list.

—Jens_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >logic problem. adding sine wave pattern to dynamic float (From: Chunk 1978 <email@hidden>)

  • Prev by Date: Re: Extract ID Value Into UILabel.
  • Next by Date: Re: Debugging (apparently) random retain loop bug (NSArrayController)
  • Previous by thread: logic problem. adding sine wave pattern to dynamic float
  • Next by thread: Re: logic problem. adding sine wave pattern to dynamic float
  • Index(es):
    • Date
    • Thread