moviepy.video.tools.credits.CreditsClip#

class moviepy.video.tools.credits.CreditsClip(creditfile, width, color='white', stroke_color='black', stroke_width=2, font='Impact-Normal', font_size=60, bg_color=None, gap=0)[source]#

Credits clip.

Parameters:

creditfile

A string or path like object pointing to a text file whose content must be as follows:

# This is a comment
# The next line says : leave 4 blank lines
.blank 4

..Executive Story Editor
MARCEL DURAND

..Associate Producers
MARTIN MARCEL
DIDIER MARTIN

..Music Supervisor
JEAN DIDIER

width

Total width of the credits text in pixels

gap

Horizontal gap in pixels between the jobs and the names

color

Color of the text. See TextClip.list('color') for a list of acceptable names.

font

Name of the font to use. See TextClip.list('font') for the list of fonts you can use on your computer.

font_size

Size of font to use

stroke_color

Color of the stroke (=contour line) of the text. If None, there will be no stroke.

stroke_width

Width of the stroke, in pixels. Can be a float, like 1.5.

bg_color

Color of the background. If None, the background will be transparent.

Returns:

An ImageClip instance that looks like this and can be scrolled to make some credits:

Executive Story Editor    MARCEL DURAND
   Associate Producers    MARTIN MARCEL
                          DIDIER MARTIN
      Music Supervisor    JEAN DIDIER

Return type:

image