• 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: Masking Tracking Rects
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Masking Tracking Rects


  • Subject: Re: Masking Tracking Rects
  • From: Bill Bumgarner <email@hidden>
  • Date: Wed, 19 Sep 2007 22:44:28 -0700

On Sep 19, 2007, at 9:50 PM, Jason Barker wrote:
So I tried adding one tracking rectangle to the view and then another
one to the view with the same bounds. And when I mouse over that area
of the view, it seems as through a mouse entered event is fired for
each tracking rectangle. So adding a tracking rectangle that overlaps
another does not produce a masking effect.

Does anyone have a better idea?

Have you determined that the extra events are problematic? .... cause a performance issue that is significant enough to warrant trying to go beyond simply minimizing the area of the tracking rect(s) and doing a bit of math to see if the mouse is really over something that needs to be redrawn?


Unless you have an unbelievably complex boundary to track, the cost of doing a bit of hit detection math is going to be orders of magnitude less than the cost of actually drawing state changes as the mouse moves. Doubly so if you are using anything like shadows, reflections, or partial transparency.

b.bum

_______________________________________________

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: 
 >Masking Tracking Rects (From: "Jason Barker" <email@hidden>)
 >Re: Masking Tracking Rects (From: "I. Savant" <email@hidden>)
 >Re: Masking Tracking Rects (From: "Jason Barker" <email@hidden>)
 >Re: Masking Tracking Rects (From: "Jason Barker" <email@hidden>)

  • Prev by Date: Re: Masking Tracking Rects
  • Next by Date: Re: Left Side Bar
  • Previous by thread: Re: Masking Tracking Rects
  • Next by thread: calling willChangeValueForKey on NSManagedObject causes fetch of unrelated to-many relationships
  • Index(es):
    • Date
    • Thread