Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Output video is garbled, single frames output are fine #651

Closed
fyxme opened this issue Oct 5, 2017 · 2 comments
Closed

Output video is garbled, single frames output are fine #651

fyxme opened this issue Oct 5, 2017 · 2 comments

Comments

@fyxme
Copy link

fyxme commented Oct 5, 2017

I'm having issues when exporting the video. It does render but it does not render correctly.
I'm trying to make a compilation of videos. The first video is always fine but the rest are all garbled.

OS : OS X EL Capitan v.10.11.6

This is how I concatenate all the clips and add the audio to it.
I used the write_videofile parameters from issue #356 (direct link to comment) but I'm still getting the issue...

final_audio = mp.AudioFileClip(music_fp)

# clip_list is a list of CompositeVideoClip
final_clip = mp.concatenate_videoclips(clip_list).fadein(2).fadeout(2)

final_clip = final_clip.set_audio(final_audio.set_duration(int(final_clip.duration)))

final_clip.write_videofile(
        output_fp,
        verbose=True,
        codec="libx264",
        audio_codec='aac',
        temp_audiofile='temp-audio.m4a',
        remove_temp=True,
        preset="medium",
        ffmpeg_params=["-profile:v","baseline", "-level","3.0","-pix_fmt", "yuv420p"])

Garbled output example

screen shot 2017-10-05 at 11 18 10 am

I know this shouldn't be posted here but more on Stackoverflow or the moviepy subreddit but it seems to take forever to get even a single response on either of those. Thanks in advance for your help

@fyxme
Copy link
Author

fyxme commented Oct 5, 2017

I managed to fix this, I needed to add a method="compose" parameter to concatenate_videoclips() most likely because my clips might have been of different sizes.

@keikoro
Copy link
Collaborator

keikoro commented Nov 25, 2017

Hi @Hexagonist, will close this issue as you managed to resolve your problem.

@keikoro keikoro closed this as completed Nov 25, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants