Skip to content

Commit

Permalink
finished pairing animations - added proper fadeout
Browse files Browse the repository at this point in the history
  • Loading branch information
martawleklinska committed Jul 16, 2024
1 parent 3da6318 commit 5bf12d6
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 23 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/render.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,5 +46,5 @@ jobs:
- uses: actions/upload-artifact@v3
with:
name: Movie HQ
path: media/videos/main/**/EllipticCurves.mp4
path: media/videos/main/1080p60/EllipticCurves.mp4
retention-days: 5
Binary file modified data/sound/episode3/slide2-2.mp3
Binary file not shown.
Binary file modified data/sound/episode3/slide2-2_1.mp3
Binary file not shown.
28 changes: 14 additions & 14 deletions zkmarek/video/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,21 +178,21 @@

EPISODE3 = [
# Intro(sound="data/sound/teaser2/slide0-0.mp3"),
# Sponsored(),
# Introduction(),
# TitleSlide("Pairing", sound="data/sound/episode3/slide1-3.mp3", wait_time=3),
Sponsored(),
Introduction(),
TitleSlide("Pairing", sound="data/sound/episode3/slide1-3.mp3", wait_time=3),
Pairing(),
# TitleSlide("Trusted setup"),
# TrustedSetup(),
# Ceremony(),
# CeremonyVerification(),
# CeremonyVerification2(),
# TitleSlide("KZG", subtitle="Kate, Zaverucha and Goldberg"),
# PolynomialCommitment(),
# KZG(),
# Verkle(),
# Subscribe("data/sound/episode1/s28.wav"),
# Credits2(),
TitleSlide("Trusted setup"),
TrustedSetup(),
Ceremony(),
CeremonyVerification(),
CeremonyVerification2(),
TitleSlide("KZG", subtitle="Kate, Zaverucha and Goldberg"),
PolynomialCommitment(),
KZG(),
Verkle(),
Subscribe("data/sound/episode1/s28.wav"),
Credits2(),
]

EPISODE4 = [
Expand Down
22 changes: 14 additions & 8 deletions zkmarek/video/slides/episode3/pairing.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from manim import DOWN, UP, Brace, FadeIn, FadeOut, MathTex, Text, Unwrite, Write, VGroup, TransformMatchingShapes, Indicate
from manim import DOWN, UP, RIGHT, Brace, FadeIn, FadeOut, MathTex, Text, Unwrite, Write, VGroup, TransformMatchingShapes, Indicate

from zkmarek.video.constant import PRIMARY_COLOR, SECONDARY_COLOR, PRIMARY_FONT, HIGHLIGHT_COLOR
from zkmarek.video.slides.common.slide_base import SlideBase
Expand Down Expand Up @@ -67,16 +67,16 @@ def construct(self):
self.multiplying_brace_label = Text(r"a times", font_size=30, color=PRIMARY_COLOR, font = PRIMARY_FONT)
self.multiplying_brace.put_at_tip(self.multiplying_brace_label)
self.non_degeneracy_label = Text("Non-degeneracy", font_size=40, color=SECONDARY_COLOR, font = PRIMARY_FONT)
nd_text = r"\forall{a \in G_1}, \forall{b \in G_2} (a, b \neq \mathcal{O}"
nd_text += r" \Rightarrow e(a, b) \neq 1_{G_T}) "
nd_text = r"\forall{a \in G_1}, \forall{b \in G_2} ({{a, b \neq \mathcal{O}}}"
nd_text += r" \Rightarrow e(a, b) \neq {{1_{G_T})}} "
self.non_degeneracy = MathTex(nd_text, font_size=40, color=SECONDARY_COLOR)
self.computability_label = Text("Computability", font_size=40, color=SECONDARY_COLOR, font = PRIMARY_FONT)

self.definition_label.to_edge(UP)
self.definition.next_to(self.definition_label, DOWN)
self.bilinearity_label.next_to(self.definition, DOWN, buff=0.8)
self.bilinearity.next_to(self.bilinearity_label, DOWN)
self.non_degeneracy_label.next_to(self.bilinearity, DOWN, buff=0.6)
self.non_degeneracy_label.next_to(self.bilinearity, DOWN, buff=1)
self.non_degeneracy.next_to(self.non_degeneracy_label, DOWN)
self.computability_label.next_to(self.non_degeneracy, DOWN, buff=0.6)

Expand All @@ -86,14 +86,14 @@ def animate_in(self, scene):
scene.play(Write(self.definition))

scene.play(FadeIn(self.brace1, self.brace2))
scene.play(FadeIn(self.brace1_label))
scene.wait(2.4)
scene.play(FadeIn(self.brace1_label.shift(RIGHT)))
scene.wait(2)
scene.play(FadeOut(self.brace1, self.brace2), FadeOut(self.brace1_label))

scene.play(FadeIn(self.brace3))
scene.play(FadeIn(self.brace3_label))
scene.play(FadeOut(self.brace3), FadeOut(self.brace3_label))
scene.wait(3)
scene.wait(3.3)
scene.play(Indicate(self.definition[0], color = HIGHLIGHT_COLOR, scale_factor=2))

self.new_subsection(scene, "bilinear definition", "data/sound/episode3/slide2-1.mp3")
Expand Down Expand Up @@ -122,12 +122,18 @@ def animate_in(self, scene):
scene.play(Write(self.multiplying), Write(self.multiplying_brace), Write(self.multiplying_brace_label))
scene.wait(4)
scene.play(Unwrite(self.multiplying), Unwrite(self.multiplying_brace), Unwrite(self.multiplying_brace_label))
scene.wait(1)
scene.play(Indicate(self.bilinearity3, color = PRIMARY_COLOR))
scene.wait(2)
scene.play(FadeOut(self.bilinearity_morph))
# scene.play(FadeOut(self.bilinearity_morph.texs[-1]))

self.new_subsection(scene, "non degeneracy", "data/sound/episode3/slide2-5.mp3")
scene.play(Write(self.non_degeneracy_label))
scene.play(Write(self.non_degeneracy))
scene.wait(2.4)
scene.play(Indicate(self.non_degeneracy[1], color = PRIMARY_COLOR))
scene.wait(2)
scene.play(Indicate(self.non_degeneracy[3], color = PRIMARY_COLOR))

self.new_subsection(scene, "computability", "data/sound/episode3/slide2-6.mp3")
scene.play(Write(self.computability_label))
Expand Down

0 comments on commit 5bf12d6

Please sign in to comment.