summaryrefslogtreecommitdiff
blob: 1e0d077532a472d3d0f9f90488911e912d0f25da (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
From 43e6087ec9bdbb23b8bb61c07efe6490fab23d73 Mon Sep 17 00:00:00 2001
From: skef <6175836+skef@users.noreply.github.com>
Date: Thu, 19 Mar 2020 17:16:20 -0700
Subject: [PATCH] Tilepath fix (#4231)

---
 fontforgeexe/tilepath.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fontforgeexe/tilepath.c b/fontforgeexe/tilepath.c
index b329b54098..2575058eb4 100644
--- a/fontforgeexe/tilepath.c
+++ b/fontforgeexe/tilepath.c
@@ -571,7 +571,7 @@ static void AdjustPoint(TD *td,Spline *spline,bigreal t, FitPoint *to) {
 	} else {
 	    bigreal s=(dy1*dx2/dy2-dx1);
 	    if ( s>-.00001 && s<.00001 ) {	/* essentially parallel */
-		to->p.x = x1; to->y = y1;
+		to->p.x = x1; to->p.y = y1;
 	    } else {
 		bigreal t1 = (x1-x2- dx2/dy2*(y1-y2))/s;
 		to->p.x = x1 + dx1*t1;
@@ -610,7 +610,7 @@ static SplinePoint *TDMakePoint(TD *td,Spline *old,real t) {
 
     AdjustPoint(td,old,t,&fp);
     new = chunkalloc(sizeof(SplinePoint));
-    new->me.x = tp.p.x; new->me.y = tp.p.y;
+    new->me.x = fp.p.x; new->me.y = fp.p.y;
     new->nextcp = new->me;
     new->prevcp = new->me;
     new->nonextcp = new->noprevcp = true;