From 4cdb9db0f6caf7f75302a3c31a8ea042831a172a Mon Sep 17 00:00:00 2001 From: Ryan Oldenburg Date: Tue, 26 Jan 2021 16:55:33 -0600 Subject: [PATCH] 2x faster lol --- src/pixie/paths.nim | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/pixie/paths.nim b/src/pixie/paths.nim index c24a8d3..50e7ddd 100644 --- a/src/pixie/paths.nim +++ b/src/pixie/paths.nim @@ -831,6 +831,8 @@ proc fillShapes( if bounds.y > y.float32 or bounds.y + bounds.h < y.float32: continue for (segment, winding) in shape: + if segment.at.y > yLine or segment.to.y < y.float32: + continue var at: Vec2 if scanline.intersects(segment, at):# and segment.to != at: if numHits == hits.len: