✨ feat: Add video transition effects (fadein, fadeout)
This commit is contained in:
11
app/services/utils/video_effects.py
Normal file
11
app/services/utils/video_effects.py
Normal file
@@ -0,0 +1,11 @@
|
||||
from moviepy import Clip, vfx
|
||||
|
||||
|
||||
# FadeIn
|
||||
def fadein_transition(clip: Clip, t: float) -> Clip:
|
||||
return clip.with_effects([vfx.FadeIn(t)])
|
||||
|
||||
|
||||
# FadeOut
|
||||
def fadeout_transition(clip: Clip, t: float) -> Clip:
|
||||
return clip.with_effects([vfx.FadeOut(t)])
|
||||
Reference in New Issue
Block a user