• 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
Fading audio in NSMovieView
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Fading audio in NSMovieView


  • Subject: Fading audio in NSMovieView
  • From: Dave Rosborough <email@hidden>
  • Date: Sat, 4 Oct 2003 12:35:53 -0700

Hello all.

I'm trying to fade audio while an NSMovieView is playing a movie. The approach I've taken is to create an NSTimer that calls a method in the movie view to reduce the volume by a fixed increment. Generally, the timer's interval will end up being somewhere in the range of 0.1 seconds. My problem is that the timer isn't firing anywhere near often enough, since the CPU is too busy playing the (rather large) movie files. It works fine on movies that are very small in size, but as soon as my movies hit 40-50 MB's the results are unsatisfactory.

Is there an obvious solution I'm missing? I've looked through the Quicktime API and tried a variety of things like prerolling the movie, calling the SetMovieVolume() function rather than the -setVolume method of NSMovieView, etc. Would placing the timer in a separate thread help (I'm a little uncertain when it comes to multithreading)? Is there a better way to do this altogether (using some sort of QuickTime plugin perhaps)?

Thanks,
DaveR
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Fading audio in NSMovieView
      • From: "Douglas A. Welton" <email@hidden>
    • Re: Fading audio in NSMovieView
      • From: "Alastair J.Houghton" <email@hidden>
  • Prev by Date: Re: Newbie NSView confusion
  • Next by Date: Re: adding byte by byte to a NSMutableData object
  • Previous by thread: Re: NSUserDefault at first startup
  • Next by thread: Re: Fading audio in NSMovieView
  • Index(es):
    • Date
    • Thread