When using the loop vfx with an n smaller than 1 (or a duration smaller than original duration),
the audio clip will cut unexpectedly.
from moviepy.editor import *
PATH = ""
vid = VideoFileClip(PATH)
vid = vid.fx(vfx.loop, n=0.5)
vid.write_videofile("render.mp4")
# The resulting file length will be half of the original, as intended.
# However, In the rendered file, the audio will cut halfway through! (a quarter of original duration)
@RealA10N , @tburrows13 I was able to reproduce this for the current moviepy version.
PR #1373 should fix this.
I used big_buck_bunny_0_30.webm found in media folder for video clip and on giving n=0.5, the clip is generated fine. Audio is not cut halfway.
I can confirm that #1373 fix this :+1:
Most helpful comment
@RealA10N , @tburrows13 I was able to reproduce this for the current moviepy version.
PR #1373 should fix this.
I used
big_buck_bunny_0_30.webmfound in media folder for video clip and on giving n=0.5, the clip is generated fine. Audio is not cut halfway.