mirror of
https://github.com/3b1b/manim.git
synced 2025-08-31 23:58:32 +00:00
Add a testing script
This commit is contained in:
parent
31478c523c
commit
7d534ab0d4
2 changed files with 18 additions and 1 deletions
|
@ -20,7 +20,7 @@ elif os.path.exists("media_dir.txt"):
|
|||
else:
|
||||
MEDIA_DIR = os.path.join(
|
||||
os.path.expanduser('~'),
|
||||
"Dropbox (3Blue1Brown)/3Blue1Brown Team Folder"
|
||||
"Videos/"
|
||||
)
|
||||
|
||||
if not os.path.exists(MEDIA_DIR):
|
||||
|
|
17
test1.py
Normal file
17
test1.py
Normal file
|
@ -0,0 +1,17 @@
|
|||
from big_ol_pile_of_manim_imports import *
|
||||
|
||||
class Shapes(Scene):
|
||||
#A few simple shapes
|
||||
def construct(self):
|
||||
circle = Circle()
|
||||
square = Square()
|
||||
line=Line(np.array([3,0,0]),np.array([5,0,0]))
|
||||
triangle=Polygon(np.array([0,0,0]),np.array([1,1,0]),np.array([1,-1,0]))
|
||||
|
||||
self.add(line)
|
||||
self.play(ShowCreation(circle))
|
||||
self.play(FadeOut(circle))
|
||||
self.play(GrowFromCenter(square))
|
||||
self.play(Transform(square,triangle))
|
||||
|
||||
#python3 extract_scene.py test1.py Shapes -r 1080
|
Loading…
Add table
Reference in a new issue