diff --git a/brush-strokes/src/lib/Calligraphy/Brushes.hs b/brush-strokes/src/lib/Calligraphy/Brushes.hs index 4880b8c..a1d0b53 100644 --- a/brush-strokes/src/lib/Calligraphy/Brushes.hs +++ b/brush-strokes/src/lib/Calligraphy/Brushes.hs @@ -207,14 +207,12 @@ tearDropBrushFn _ mkI = h = runD ( var @_ @k ( Fin 2 ) ) params mkPt :: Double -> Double -> D k ( I i rec ) ( I i ( ℝ 2 ) ) mkPt x y - -- 1. translate the teardrop so that the center of mass is at the origin + -- 1. translate the teardrop so that the centre of mass is at the origin -- 2. scale the teardrop so that it has the requested width/height - -- 3. rotate - = let !x' = w `scaledBy` (x / tearWidth) - !y' = ( h `scaledBy` ( ( y - tearCenter ) / tearHeight) ) - in - x' *^ e_x - ^+^ y' *^ e_y + -- 3. rotate (done separately) + = let !x' = w `scaledBy` ( x / tearWidth ) + !y' = h `scaledBy` ( ( y - tearCenter ) / tearHeight ) + in x' *^ e_x ^+^ y' *^ e_y in sequenceA $ Spline { splineStart = mkPt 0 0