reorganize pile of old scripts

This commit is contained in:
Grant Sanderson
2015-10-06 12:16:55 -07:00
parent c99a1dfd6a
commit 0bf582a1bc
11 changed files with 33 additions and 0 deletions

View File

@ -0,0 +1,33 @@
#!/usr/bin/env python
import numpy as np
import itertools as it
from copy import deepcopy
import sys
from animation import *
from mobject import *
from constants import *
from region import *
from scene import Scene
from script_wrapper import command_line_create_scene
MOVIE_PREFIX = "matrix_as_transform_2d/"
class TransformScene2D(Scene):
def construct(self):
pass
class SampleScene(Scene):
def construct(self):
self.add(Grid())
self.add(Line(LEFT+SPACE_HEIGHT*DOWN, RIGHT+SPACE_HEIGHT*UP))
self.dither()
def func((x, y, z)):
return ((SPACE_HEIGHT+y)*x, y, z)
self.apply(ApplyPointwiseFunction, func, interpolation_function = clockwise_path)
self.dither()
if __name__ == "__main__":
command_line_create_scene(MOVIE_PREFIX)