From 20ab6150be8e81582436dd7946752676bee2c326 Mon Sep 17 00:00:00 2001 From: "u7511759@anu.edu.au" Date: Sun, 19 Oct 2025 18:01:27 +1100 Subject: [PATCH 1/2] infinite stroke width array nesting fix --- manim/mobject/opengl/opengl_vectorized_mobject.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/manim/mobject/opengl/opengl_vectorized_mobject.py b/manim/mobject/opengl/opengl_vectorized_mobject.py index 766c3029a9..16f8caf40e 100644 --- a/manim/mobject/opengl/opengl_vectorized_mobject.py +++ b/manim/mobject/opengl/opengl_vectorized_mobject.py @@ -283,7 +283,10 @@ def set_stroke( if width is not None: for mob in self.get_family(recurse): - mob.stroke_width = np.array([[width] for width in tuplify(width)]) + if not isinstance(width, np.ndarray): + mob.stroke_width = np.array([[width] for width in tuplify(width)]) + else: + mob.stroke_width = width if background is not None: for mob in self.get_family(recurse): From 58fbb42b0ce6671c8f167b327797b28ae28305c9 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sun, 19 Oct 2025 08:40:16 +0000 Subject: [PATCH 2/2] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- manim/mobject/opengl/opengl_vectorized_mobject.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manim/mobject/opengl/opengl_vectorized_mobject.py b/manim/mobject/opengl/opengl_vectorized_mobject.py index 16f8caf40e..c8e58da9a0 100644 --- a/manim/mobject/opengl/opengl_vectorized_mobject.py +++ b/manim/mobject/opengl/opengl_vectorized_mobject.py @@ -285,7 +285,7 @@ def set_stroke( for mob in self.get_family(recurse): if not isinstance(width, np.ndarray): mob.stroke_width = np.array([[width] for width in tuplify(width)]) - else: + else: mob.stroke_width = width if background is not None: