Skip to content

Commit

Permalink
Fix issue Zulko#2247
Browse files Browse the repository at this point in the history
Fixes the issue when concatenating videoclips as mask is being considered as [1, 1] so the mask shape is different from the other videos and fails.

I think [1, 1] could be a default mask to avoid divisions by zero or something similar, but here it does not make sense.

Issue here: Zulko#2247
  • Loading branch information
Implosiv3 authored Nov 27, 2024
1 parent 874e91f commit f47f317
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion moviepy/video/compositing/CompositeVideoClip.py
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ def frame_function(t):
return clips[i].get_frame(t - timings[i])

def get_mask(clip):
mask = clip.mask or ColorClip([1, 1], color=1, is_mask=True)
mask = clip.mask or ColorClip(clip.size, color=1, is_mask=True)
if mask.duration is None:
mask.duration = clip.duration
return mask
Expand Down

0 comments on commit f47f317

Please sign in to comment.