From 5ef8f2b4491ad1df4b380bdcf6c3a9d52da2eabe Mon Sep 17 00:00:00 2001 From: Luka Rahne Date: Sat, 9 Nov 2024 12:33:45 +0100 Subject: [PATCH 1/3] fix Prism rendering --- manim/mobject/three_d/three_dimensions.py | 1 + 1 file changed, 1 insertion(+) diff --git a/manim/mobject/three_d/three_dimensions.py b/manim/mobject/three_d/three_dimensions.py index 7b30f9a7ad..31473fc141 100644 --- a/manim/mobject/three_d/three_dimensions.py +++ b/manim/mobject/three_d/three_dimensions.py @@ -555,6 +555,7 @@ def generate_points(self) -> None: for dim, value in enumerate(self.dimensions): self.rescale_to_fit(value, dim, stretch=True) + init_points = generate_points class Cone(Surface): """A circular cone. From b755ae2c11e6fc7f4dbf69994e52fd1bdba95b14 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sat, 9 Nov 2024 11:36:58 +0000 Subject: [PATCH 2/3] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- manim/mobject/three_d/three_dimensions.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/manim/mobject/three_d/three_dimensions.py b/manim/mobject/three_d/three_dimensions.py index 31473fc141..582167adb3 100644 --- a/manim/mobject/three_d/three_dimensions.py +++ b/manim/mobject/three_d/three_dimensions.py @@ -555,7 +555,8 @@ def generate_points(self) -> None: for dim, value in enumerate(self.dimensions): self.rescale_to_fit(value, dim, stretch=True) - init_points = generate_points + init_points = generate_points + class Cone(Surface): """A circular cone. From 4078a01e60135638aa4ca03ab12c402c14cf82b3 Mon Sep 17 00:00:00 2001 From: Luka Rahne Date: Sun, 24 Nov 2024 21:05:04 +0100 Subject: [PATCH 3/3] fix Prism rendering - fix dispatching in base class --- manim/mobject/three_d/three_dimensions.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/manim/mobject/three_d/three_dimensions.py b/manim/mobject/three_d/three_dimensions.py index 582167adb3..5539e7fbe0 100644 --- a/manim/mobject/three_d/three_dimensions.py +++ b/manim/mobject/three_d/three_dimensions.py @@ -517,7 +517,8 @@ def generate_points(self) -> None: self.add(face) - init_points = generate_points + def init_points(self) -> None: + self.generate_points() class Prism(Cube): @@ -555,8 +556,6 @@ def generate_points(self) -> None: for dim, value in enumerate(self.dimensions): self.rescale_to_fit(value, dim, stretch=True) - init_points = generate_points - class Cone(Surface): """A circular cone.