From 9c03a40d682cbcd2767741a64fd47cefc0eb3118 Mon Sep 17 00:00:00 2001 From: Grant Sanderson Date: Thu, 2 Feb 2023 10:39:30 -0800 Subject: [PATCH] Account for unnecessary calls to use_winding_fill --- manimlib/mobject/types/vectorized_mobject.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/manimlib/mobject/types/vectorized_mobject.py b/manimlib/mobject/types/vectorized_mobject.py index 47dfeef5..7b95030e 100644 --- a/manimlib/mobject/types/vectorized_mobject.py +++ b/manimlib/mobject/types/vectorized_mobject.py @@ -867,8 +867,10 @@ class VMobject(Mobject): # Alignment def align_points(self, vmobject: VMobject) -> Self: winding = self._use_winding_fill and vmobject._use_winding_fill - self.use_winding_fill(winding) - vmobject.use_winding_fill(winding) + if winding != self._use_winding_fill: + self.use_winding_fill(winding) + if winding != vmobject._use_winding_fill: + vmobject.use_winding_fill(winding) if self.get_num_points() == len(vmobject.get_points()): # If both have fill, and they have the same shape, just # give them the same triangulation so that it's not recalculated