Last active
August 19, 2018 12:28
-
-
Save robkorv/797890fc121a7f78bf17f94d7b3732e4 to your computer and use it in GitHub Desktop.
Avisynth script behind https://www.youtube.com/watch?v=zKl8XTh16iw
This file contains hidden or 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
| # http://avisynth.nl/index.php/Main_Page | |
| ## files | |
| rob_f = "robkorv-pov.mkv" | |
| born_f = "bornnnie-pov.mkv" | |
| ## index it https://github.com/FFMS/ffms2/blob/master/doc/ffms2-avisynth.md#limitations | |
| FFIndex(rob_f) | |
| FFIndex(born_f) | |
| ## clips | |
| rob_c = AudioDub(FFVideoSource(rob_f), FFAudioSource(rob_f)) | |
| # duplicated some frames to make it more in sync with rob_c | |
| born_c = AudioDub(FFVideoSource(born_f), FFAudioSource(born_f)).DuplicateFrame(1, 1, 1, 1, 1, 1) | |
| blank_c = BlankClip(Int(rob_c.FrameRate * 5), rob_c.Width, rob_c.Height, fps=rob_c.FrameRate, pixel_type=rob_c.PixelType, audio_rate=rob_c.AudioRate, channels=rob_c.AudioChannels) | |
| ## subs | |
| sub1 = Subtitle(blank_c, "In the next clip, take a good look at the timer!", size=72.0, align=5) | |
| sub2 = Subtitle(blank_c, "Let's look at that again :)", size=72.0, align=5) | |
| sub3 = Subtitle(blank_c, "By the way... Bornnnie is legendary!", size=72.0, align=5) | |
| ## overlays | |
| # full screen rob with born in corner overlayed | |
| born_small_c = Spline64Resize(born_c, 640, 360) | |
| rob_born_c = Overlay(rob_c, born_small_c, rob_c.Width - born_small_c.Width - 25, 50) | |
| # full screen born with rob in corner overlayed | |
| rob_small_c = Spline64Resize(rob_c, 640, 360) | |
| born_rob_c = Overlay(born_c, rob_small_c, rob_c.Width - rob_small_c.Width - 25, 50) | |
| ## timer | |
| # until frame 735, show time | |
| timer = ShowSMPTE(rob_born_c, offset="00:04:47:42", y=rob_c.Height / 2, size=172).Trim(0, 735) | |
| # after frame 736, show the frag time as a big sub | |
| big_time = Subtitle(rob_born_c.Trim(736, 0), "00:04:59:57", size=356, align=5) | |
| rob_born_timer_c = timer + big_time | |
| ## slomo | |
| left = Trim(rob_born_timer_c, 0, 618) | |
| # slomo is from frame 619 to 798, slowed down to 3.33 fps with audio slowdown | |
| # then converted to 60fps by duplicating frames and the audio to 48000hz again | |
| middle = Trim(rob_born_timer_c, 619, 798).AssumeFPS(rob_c.FrameRate / 16, true).ConvertFPS(rob_c.FrameRate).SSRC(rob_c.AudioRate) | |
| right = Trim(rob_born_timer_c, 799, rob_c.FrameCount) | |
| rob_timer_slomo_c = left + middle + right | |
| # return vid | |
| return sub1 + rob_born_c + sub2 + rob_timer_slomo_c + sub3 + born_rob_c |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment