question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Clip is totally transparent when crossfadeout effect starts with time resized clip.

See original GitHub issue

This is a small example where the issue occurs. I may do something wrong but I wondering how to get this to work.

#!/usr/bin/python3.8
# -*- coding: utf-8 -*-

from moviepy.editor import *


clip1 = ColorClip((200,200),color=(255,0,0),duration=10)
clip2 = ColorClip((200,200),color=(0,255,0),duration=10)

clip1 = clip1.set_position((860,440))
clip2 = clip2.set_position((860,440))

clip1 = clip1.set_end(10).crossfadeout(1)
clip2 = clip2.set_start(clip1.end - 1).crossfadein(1)
clip2 = clip2.set_end(20).crossfadeout(1)

# Those two lines cause the issue
clip1 = clip1.resize(lambda t: 1 + 0.05 * t)
clip2 = clip2.resize(lambda t: 1 + 0.05 * t)

compo = CompositeVideoClip([clip1,clip2], size=[1920,1080], use_bgclip=False, bg_color=(0,0,0))
compo.write_videofile("example.mp4", fps=30)

Expected Behavior

I want my clip to get bigger and to fadeout to let the next clip appears.

Actual Behavior

If I try to resize the clip given the time, when the fadeout should start, the clip disappears. If I comment out the resize part, the clips are shown as I expect but, I really need to resize them.

Steps to Reproduce the Problem

Just run my example, try with or without the resize part.

Specifications

  • Python Version: 3.8
  • Moviepy Version: v1.0.3
  • Platform Name: Ubuntu
  • Platform Version: 18.04

Thank you! Regards.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
tburrows13commented, May 17, 2020

Hello, thanks for the report. I can confirm that I can replicate this issue.

0reactions
tburrows13commented, May 23, 2020

It will get closed when #1200 is merged into master 😃. Good to know that it worked!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Classes of Video Clips — MoviePy documentation
This method is intensively used to produce new clips every time there is an outplace transformation of the clip (clip.resize, clip.subclip, etc.).
Read more >
CHANGELOG.md · Gitee 极速下载/moviepy - Gitee.com
When using VideoClip.write_videofile() with write_logfile=True , errors would not be properly reported #890 ; TextClip.list("color") now returns a list of bytes, ...
Read more >
Soundop User Guide - Ivosight
You can view and edit the spectrum directly with effects and processing tools such as. Noise Reduction, Time Stretch and Normalize in the...
Read more >
Full step by step video editing in Adobe premiere pro CC
That video clips, pictures and music and sound effects. So you can put over your video or pictures to create a movie. If...
Read more >
MoviePlus Companion
Product at the time you upgraded the Software Product. ... Repeating media clips . ... with music, or pull a sound effect from...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found