From: "TIM THIESSEN" Received: from resqmta-po-04v.sys.comcast.net ([96.114.154.163] verified) by media-motion.tv (CommuniGate Pro SMTP 6.1.0) with ESMTPS id 6453558 for ae-list@media-motion.tv; Mon, 21 May 2018 22:12:08 +0200 Received: from resomta-po-09v.sys.comcast.net ([96.114.154.233]) by resqmta-po-04v.sys.comcast.net with ESMTP id Kl0KfR8BiN7zjKrGbft8si; Mon, 21 May 2018 20:18:49 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net; s=q20161114; t=1526933929; bh=zyfA4wk9PLjbEVz7Nh/1cTh5lOj4BY/yyFxa5PDF4YE=; h=Received:Received:Date:From:Reply-To:To:Message-ID:Subject: MIME-Version:Content-Type; b=G32Ezn3CW7H+l5AnNaM2YweWdJyZGN04PM17xq5tAxSnyHjdLB9d28RqEQTXDrZYo Kda7opmvIYot7hWvewJtPm/s6438veeav9V8STDk+h73hb2Opt+R6S33FwR2PWIRer z/FrMUb1Q58qJtEn4fi8nslMRN8IJptPEYug3Gaby5PtO+DfgAHGgqLa3Q1nKbb9i+ QZ5wnMOGf86SaDKkjurBMK0csYbuW0sU+Qo1AGc5H+1CBU6U3XoQdi5yXvJiSmJco/ TK5qf06T24qk4mrMoh9eIzk2ZqfjIjlPguqYRvaYOG08/iwD8C2RSkMTp9PuzWGz/U W4qx4yL+BlkYg== Received: from oxapp-hoc-34o.email.comcast.net ([96.118.241.153]) by resomta-po-09v.sys.comcast.net with ESMTPS id KrGbf6TkHwLQoKrGbf9RAd; Mon, 21 May 2018 20:18:49 +0000 Date: Mon, 21 May 2018 13:18:48 -0700 (PDT) Reply-To: TIM THIESSEN To: After Effects Mail List Message-ID: <543033323.205167.1526933928973@connect.xfinity.com> In-Reply-To: References: Subject: Re: [AE] inTangents/outTangents Math MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_205166_752451669.1526933928967" X-Priority: 3 Importance: Medium X-Mailer: Open-Xchange Mailer v7.8.4-Rev12 X-Originating-IP: ::ffff:107.1.199.10 X-Originating-Client: open-xchange-appsuite X-CMAE-Envelope: MS4wfNR625qkzNVtoTLdP7t8hiPMFBwX8tukb0BYtiFNs9Vz0ByeMp9f975DjihM/OxjTWDYbWEUumkc25TVUaHp2Vv2QGR0i2jRVFLIfcxHqUFxhzIpoM4C +05/L7zUEz/6TJA2jJwFmZzNrnw5Zzsk4Y4aAlScrrOmmezvrH+k2Y/HDk9FDJ7ByX2D8fdpZOVvKpG2eg2ObXKZMPQQgtWBdnc= ------=_Part_205166_752451669.1526933928967 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Thanks Dan this is the answer I was looking for - I think one thing that wa= s confusing me was that I was thinking in/outTangents were actual points ra= ther than relative point so I was looking to find the real x,y point rather= than how they related to the point like a parent/child relationship. Hope = I got that correct, thanks for clearing this up and for the actual math. Tim T > On May 21, 2018 at 12:54 PM Dan Ebberts wrote: >=20 >=20 > Just from looking at how AE does it, the math doesn=E2=80=99t seem al= l that complex. For all the points except the first and last, it looks like= you just subtract the previous point from the next point and divide that v= ector by 6 to get the out tangent of the current point. Then invert that fo= r the in tangent. >=20 > =20 >=20 > If the path is closed, for the first and last point you wrap around. = So, for the first point you would subtract the last point from the 2nd poin= t, divide by 6, etc. >=20 > =20 >=20 > If the path is open, for the first point you would subtract the first= point from the second point and divide by 6 for the out tangent and use [0= ,0] for the in tangent. >=20 > =20 >=20 > Do something similar for the last point. >=20 > =20 >=20 > =20 >=20 > Dan >=20 > =20 >=20 > From: After Effects Mail List > Sent: Monday, May 21, 2018 11:02 AM > To: After Effects Mail List > Subject: Re: [AE] inTangents/outTangents Math >=20 > =20 >=20 > Thanks Chris - there is a ton of info on the web about bezier curves = and I am getting what the behind the scenes mechanism is doing - but maybe = my real question is if I create a spline via a script I want to know how to= calculate the in and out tangents to make a spline that mimics the auto be= zier path. Is that even possible? >=20 > =20 >=20 > Thanks >=20 > Tim T >=20 > > >=20 > > On May 20, 2018 at 1:22 AM Chris Zwar wrote: > >=20 > > Here=E2=80=99s a starting point. > >=20 > > =20 > >=20 > > http://jamie-wong.com/post/bezier-curves/ > >=20 > > =20 > >=20 > >=20 > >=20 > > > > >=20 > > > On 20 May 2018, at 2:39 pm, TIM THIESSEN wrote: > > >=20 > > > =20 > > >=20 > > > Can any one direct me to where I can read about calculati= ng the inTangent/outTangents of a path - I want to build a curved path (lik= e auto bezier) but I don't know the math to figure out the in/out Tangents. > > >=20 > > > =20 > > >=20 > > > Thank > > >=20 > > > Tim T > > >=20 > > > > >=20 > > =20 > >=20 > > >=20 ------=_Part_205166_752451669.1526933928967 MIME-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable

Thanks Dan this is the answer I was look= ing for - I think one thing that was confusing me was that I was thinking i= n/outTangents were actual points rather than relative point so I was lookin= g to find the real x,y point rather than how they related to the point like= a parent/child relationship. Hope I got that correct, thanks for clearing = this up and for the actual math.


Tim T

On May 21, 2018 at 12:54 PM Dan Ebberts = <AE-List@media-motion.tv> wrote:

Just from looking at ho= w AE does it, the math doesn’t seem all that complex. For all the poi= nts except the first and last, it looks like you just subtract the previous= point from the next point and divide that vector by 6 to get the out tange= nt of the current point. Then invert that for the in tangent.

 

If the path is closed, for the first and last point you wrap around. So, f= or the first point you would subtract the last point from the 2nd point, divide by 6, etc.

 

If the path is open, for the first p= oint you would subtract the first point from the second point and divide by= 6 for the out tangent and use [0,0] for the in tangent.

 

Do som= ething similar for the last point.

=  

 

Dan

 

From: After Effects Mail List <AE-List@media-motion.tv>
Se= nt: Monday, May 21, 2018 11:02 AM
To: After Ef= fects Mail List <AE-List@media-motion.tv>
Subject: Re: [AE] inTangents/outTangents Math

 

Thanks Chris - there is a ton o= f info on the web about bezier curves and I am getting what the behind the = scenes mechanism is doing - but maybe my real question is if I create a spl= ine via a script I want to know how to calculate the in and out tangents to= make a spline that mimics the auto bezier path. Is that even possible?

 

Thanks

Tim T

On May 20, 2018 at 1:22 AM Chri= s Zwar <AE-List@media-motion= .tv> wrote:

Here’s a starting point.

 

http://ja= mie-wong.com/post/bezier-curves/

 



On 20 May 2018, at 2:39 p= m, TIM THIESSEN <AE-List@med= ia-motion.tv> wrote:

=  

= Can any one direct me to where I can read about calculating th= e inTangent/outTangents of a path - I want to build a curved path (like aut= o bezier) but I don't know the math to figure out the in/out Tangents.<= /span>

 

= Thank

Tim T

 

=20 ------=_Part_205166_752451669.1526933928967--