Skip to content

Commit

Permalink
Move unit normal refreshing to VMobject
Browse files Browse the repository at this point in the history
  • Loading branch information
3b1b committed Jul 19, 2022
1 parent af7c58d commit cc81cc5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 0 additions & 1 deletion manimlib/mobject/mobject.py
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,6 @@ def reverse_points(self):
for mob in self.get_family():
for key in mob.data:
mob.data[key] = mob.data[key][::-1]
self.refresh_unit_normal()
return self

def apply_points_function(
Expand Down
5 changes: 5 additions & 0 deletions manimlib/mobject/types/vectorized_mobject.py
Original file line number Diff line number Diff line change
Expand Up @@ -770,6 +770,11 @@ def refresh_unit_normal(self):
mob.get_unit_normal(recompute=True)
return self

def reverse_points(self):
super().reverse_points()
self.refresh_unit_normal()
return self

# Alignment
def align_points(self, vmobject: VMobject):
if self.get_num_points() == len(vmobject.get_points()):
Expand Down

0 comments on commit cc81cc5

Please sign in to comment.