Re: Re: Re: Re: Tracking rectangles and bezier paths
Re: Re: Re: Re: Tracking rectangles and bezier paths
- Subject: Re: Re: Re: Re: Tracking rectangles and bezier paths
- From: Dave Budde <email@hidden>
- Date: Sat, 9 Sep 2006 12:18:47 -0700
Yes, that is correct. I am interested in highlighting the curve when
the mouse is on it. Apple does this very nicely in Space Designer
(part of Logic Pro). I would be interested to know how they do
this. Anyone from Apple care to comment?
Dave
On Sep 9, 2006, at 12:01 PM, email@hidden wrote:
From what Dave told, I believe he is interested in highlighting the
curve when the mouse is *on* it, as opposed to *inside* the area
defined by it. The convex hull may be too large for tracking purpose.
Raphael
On 9/9/06, Wagner Truppel <email@hidden> wrote:
It's not as hard a math problem as suggested, even if the curve is
not monotonic. Recall that the entire bezier path is contained within
the convex hull of the path's control points so a very simple
solution is to retrieve the control points, compute their convex hull
(which is a convex polygon, in 2 dimensions), and use that as your
tracking area. Computing convex hulls in 2 dimensions is almost
trivial - any decent book on algorithms will tell you how.
Wagner
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden