Re: Travelling along an NSBezierCurve in small increments
Re: Travelling along an NSBezierCurve in small increments
- Subject: Re: Travelling along an NSBezierCurve in small increments
- From: Frank Midgley <email@hidden>
- Date: Tue, 22 Mar 2005 11:46:46 -0600
On Mar 22, 2005, at 11:20AM, Rick Hoge wrote:
I am trying to sample an image along an NSBezierCurve drawn by the
user. In general the curve could consist of distant elements
connected by smooth lines using control points. Is there any
clean/simple way to obtain the x,y coordinates along such a curve at
small increments along the path? I can think of a number of brute
force methods that should work but want to make sure I'm not missing
any nice functionality provided by the framework to do this.
-[NSBezierPath bezierPathByFlatteningPath] gives you a path that is
composed of flat segments. Simple math will give you points along each
segment if needed.
-Frank
------------------------------------
Frank M. Midgley
email@hidden
http://homepage.mac.com/knarf/
_______________________________________________
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