From 2696d130e4a8fcbe61577d771014465d93e3ca6a Mon Sep 17 00:00:00 2001 From: Grant Sanderson Date: Tue, 27 Nov 2018 13:40:33 -0800 Subject: [PATCH] Tiny refactor to make ShowShadows easier to modify in subclasses --- active_projects/shadows.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/active_projects/shadows.py b/active_projects/shadows.py index cef60ae9..1e8ea60c 100644 --- a/active_projects/shadows.py +++ b/active_projects/shadows.py @@ -57,6 +57,10 @@ class ShowShadows(ThreeDScene): "camera_config": { "light_source_start_point": 10 * OUT, "frame_center": [0, 0, 0.5], + }, + "initial_orientation_config": { + "phi": 60 * DEGREES, + "theta": -120 * DEGREES, } } @@ -144,8 +148,7 @@ class ShowShadows(ThreeDScene): temp_shadow = updating_mobject_from_func(lambda: get_shadow(obj3d)) self.add(temp_shadow) self.move_camera( - phi=60 * DEGREES, - theta=-120 * DEGREES, + **self.initial_orientation_config, added_anims=[ LaggedStart(DrawBorderThenFill, obj3d) ],