variables - What is this formula involving circles trying to do? -
x, y, z = pos radius = width / 2.0 if width >= 0.0: x = -x = radius * math.pi = (x/a) * math.pi
this code snippet other me, , i've been wanting understand it. however, variable a
little ambiguous, , i'm having trouble figuring out purpose.
this snippet part of function calculates arch text displayed over.
the variable pos
position of current letter working with. variable width
width of entire line.
there nonsense usage of math.pi - result doesn't depend on it.
a = x/r = cos(fi)
, fi direction angle of (coordinate origin - starting point) vector, if r radius of arc origin center
(cos(fi) negated positive width values)
Comments
Post a Comment