mirror of
https://github.com/3b1b/manim.git
synced 2025-07-31 22:13:30 +08:00
Beginning music and measure theory
This commit is contained in:
@ -10,29 +10,13 @@ from animation import *
|
||||
from mobject import *
|
||||
from constants import *
|
||||
from region import *
|
||||
from scene import Scene, SceneFromVideo
|
||||
from scene import Scene
|
||||
from script_wrapper import command_line_create_scene
|
||||
|
||||
|
||||
class SampleScene(SceneFromVideo):
|
||||
class SampleScene(Scene):
|
||||
def construct(self):
|
||||
path = os.path.join(MOVIE_DIR, "EdgeDetectedCountingInBinary35-75.mp4")
|
||||
SceneFromVideo.construct(self, path, time_range = (3, 5))
|
||||
self.apply_gaussian_blur(sigmaX = 10)
|
||||
self.make_all_black_or_white()
|
||||
self.name = "BlurEdgeBlurBold"
|
||||
|
||||
# self.animate_over_time_range(
|
||||
# 0, 3,
|
||||
# ApplyMethod(Dot().to_edge(LEFT).to_edge, RIGHT)
|
||||
# )
|
||||
|
||||
def make_all_black_or_white(self):
|
||||
self.frames = [
|
||||
255*(frame != 0).astype('uint8')
|
||||
for frame in self.frames
|
||||
]
|
||||
|
||||
pass
|
||||
|
||||
if __name__ == "__main__":
|
||||
command_line_create_scene()
|
Reference in New Issue
Block a user