-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adding --terry option to preprocess.py & auxiliary files
- Loading branch information
Showing
5 changed files
with
161 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,3 +8,6 @@ __pycache__/ | |
media/ | ||
photos/ | ||
*.jpg | ||
.DS_Store | ||
.log | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
settings.tex = "pdflatex"; | ||
|
||
string to_string(int x) { | ||
return (x < 10 ? "0" : "") + string(x); | ||
} | ||
|
||
void clock(string date, int h, int m) { | ||
picture pic; | ||
label(pic, graphic("screenshots/background.png"), (0,0)); | ||
layer(pic); | ||
path c = circle((0,0), 460); | ||
picture subpic; | ||
label(subpic, graphic("screenshots/filler.png"), (0,0)); | ||
clip(subpic, c); | ||
add(pic, subpic); | ||
layer(pic); | ||
draw(pic, c, black+48); | ||
for (int i=0; i<60; ++i) | ||
dot(pic, 400*dir(6*i), black+16); | ||
for (int i=0; i<12; ++i) { | ||
real l = i%3 == 0 ? 64 : 32; | ||
pair p = dir(30*i); | ||
draw(pic, (400-l)*p -- 400*p, black+24); | ||
} | ||
path hl = (0,0) -- (-5,30) -- (0,60) -- (5,30) -- cycle; | ||
fill(pic, rotate(-30*h)*scale(4)*hl, black); | ||
path ml = (0,0) -- (-5,60) -- (0,90) -- (5,60) -- cycle; | ||
fill(pic, rotate(-6*m)*scale(4)*ml, black); | ||
fill(pic, circle((0,0), 12), black); | ||
fill(pic, circle((0,0), 6), white); | ||
shipout("screenshots/" + date + "T" + to_string(h) + ":" + to_string(m) + ":00.0", pic); | ||
} | ||
|
||
string[] words = split(stdin, " "); | ||
string start = words[0]; | ||
string end = words[1]; | ||
words = split(start, "T"); | ||
string date = words[0]; | ||
words = split(words[1], ":"); | ||
int h = (int)words[0]; | ||
int m = (int)words[1]; | ||
words = split(end, "T"); | ||
words = split(words[1], ":"); | ||
int eh = (int)words[0]; | ||
int em = (int)words[1]; | ||
|
||
while (true) { | ||
clock(date, h, m); | ||
if (h == eh && m == em) break; | ||
++m; | ||
if (m == 60) { | ||
++h; | ||
m = 0; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,5 +37,8 @@ | |
3: "III", | ||
4: "IV", | ||
5: "V", | ||
6: "I", | ||
7: "II", | ||
8: "III", | ||
} | ||
TIMELAPSE_DURATION = 5 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
from manim import * | ||
|
||
class Countdown(Scene): | ||
def construct(self): | ||
for i in reversed(range(61)): | ||
t = Text(("0" if i<10 else "") + str(i), font="OCR A Extended", font_size=144) | ||
self.play(FadeIn(t, scale=0, run_time=0.5)) | ||
self.play(FadeOut(t, scale=5, run_time=0.5)) | ||
|
||
class NameMarker(Scene): | ||
def construct(self): | ||
name = "Name Surname" | ||
title = "Why are we considering him" | ||
r = Rectangle(height = 1, width = 8) | ||
r.set_fill("#C0C0C0", opacity = 0.8) | ||
r.set_stroke(width = 0) | ||
r.to_edge(RIGHT, buff=0) | ||
r.to_edge(DOWN, buff=0.5) | ||
n = Text(name, font="Futura", font_size=36, color=BLACK) | ||
t = Text(title, font="Futura", font_size=24, color=BLACK) | ||
g = VGroup() | ||
g.add(n) | ||
g.add(t) | ||
g.arrange(DOWN, center=False, aligned_edge=LEFT, buff=0) | ||
g.to_edge(LEFT, buff=6.4) | ||
g.to_edge(DOWN, buff=0.55) | ||
self.play(Wait(0.5)) | ||
self.play(Write(r)) | ||
self.play(LaggedStart(Write(n), Write(t), lag_ratio=0.3)) | ||
self.play(Wait(3)) | ||
self.play(LaggedStart(Unwrite(t), Unwrite(n), lag_ratio=0.3)) | ||
self.play(Unwrite(r)) | ||
self.play(Wait(0.5)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters