mirror of
https://github.com/3b1b/manim.git
synced 2025-09-01 00:48:45 +00:00
Refresh shader data before aligning new data
This commit is contained in:
parent
c5aa330077
commit
dd2a459eaa
1 changed files with 2 additions and 2 deletions
|
@ -1107,6 +1107,8 @@ class Mobject(object):
|
|||
self.align_data(mobject)
|
||||
|
||||
def align_data(self, mobject):
|
||||
# In case any data arrays get resized when aligned to shader data
|
||||
self.refresh_shader_data()
|
||||
for mob1, mob2 in zip(self.get_family(), mobject.get_family()):
|
||||
# Separate out how points are treated so that subclasses
|
||||
# can handle that case differently if they choose
|
||||
|
@ -1114,8 +1116,6 @@ class Mobject(object):
|
|||
for key in mob1.data:
|
||||
if key == "points":
|
||||
continue
|
||||
mob1.check_data_alignment(mob1.get_points()[:, 0], key)
|
||||
mob2.check_data_alignment(mob2.get_points()[:, 0], key)
|
||||
arr1 = mob1.data[key]
|
||||
arr2 = mob2.data[key]
|
||||
if len(arr2) > len(arr1):
|
||||
|
|
Loading…
Add table
Reference in a new issue