• 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: Optimizing NSRectFill
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Optimizing NSRectFill


  • Subject: Re: Optimizing NSRectFill
  • From: "Kyle Sluder" <email@hidden>
  • Date: Sat, 20 Dec 2008 13:51:29 -0500

On Sat, Dec 20, 2008 at 12:18 PM, Michael Ash <email@hidden> wrote:
> A simple way to do this is to avoid calling setNeedsDisplay: (or its
> friends) directly from your event handler. Instead start a timer with
> some suitably small interval, and set a flag. If the flag is already
> set, don't start the timer, it's already been started. When the timer
> fires, invalidate the view and clear the flag.

Alright, perhaps I don't completely understand how the drawing model
works at a low enough level, but why would this be helpful?  Doesn't
AppKit just coalesce updates received by -setNeedsDisplayInRect: until
Quartz has finished pushing pixels?  So if you are accumulating dirty
rects in your event handler, your drawing should still be limited to
min(as fast as possible, 60hz).

Or am I thinking of the Quartz GL pipeline?

--Kyle Sluder
_______________________________________________

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

  • Follow-Ups:
    • Re: Optimizing NSRectFill
      • From: "Michael Ash" <email@hidden>
References: 
 >Optimizing NSRectFill (From: "Oleg Krupnov" <email@hidden>)
 >Re: Optimizing NSRectFill (From: Peter Ammon <email@hidden>)
 >Re: Optimizing NSRectFill (From: "Oleg Krupnov" <email@hidden>)
 >Re: Optimizing NSRectFill (From: "Michael Ash" <email@hidden>)

  • Prev by Date: Re: NSBezierPath
  • Next by Date: Re: toolbar to view gradient displaying correctly only sometimes?
  • Previous by thread: Re: Optimizing NSRectFill
  • Next by thread: Re: Optimizing NSRectFill
  • Index(es):
    • Date
    • Thread