def example06():
    '''Cascade overlayed videos and images in top of a base video or image.'''

    # The OVERLAY display_style when applied to a clip in the window
    # makes it shrink a random amount and be played while it scrolls
    # across the base window.
    #
    # Let's use that to combine several things together and make a
    # huge mess!
    output_file = "./example_output/example06.mp4"
    base_video = vedit.Video( "./examples/i030.mp4" )

    # Let's use a different audio track for this.
    base_clip = vedit.Clip( video=base_video, display=vedit.Display( include_audio=False ) )
    base_window = vedit.Window( clips = [ base_clip ],
                                output_file=output_file,
                                duration=30,
                                audio_file="./examples/a2.mp4" )

    # Turn our cat images into clips of random length between 3 and 6
    # seconds and have them cascade across the screen from left to
    # right.
    cat_display = vedit.Display( display_style=vedit.OVERLAY,
                                 overlay_direction=vedit.RIGHT,
                                 include_audio=False,
                                 overlay_concurrency=4,
                                 overlay_min_gap=0.8 )
    cat_clips = []
    for cat_pic in glob.glob( "./examples/cat*jpg" ):
        cat_video_file = vedit.gen_background_video( bgimage_file=cat_pic,
                                                     duration=random.randint( 3, 6 ) )
        cat_video = vedit.Video( cat_video_file )
        cat_clips.append( vedit.Clip( video=cat_video, display=cat_display ) )

    # Turn our dog images into clips of random length between 2 and 5
    # seconds and have them cascade across the screen from top to
    # bottom.
    dog_display = vedit.Display( display_style=vedit.OVERLAY,
                                 overlay_direction=vedit.DOWN,
                                 include_audio=False,
                                 overlay_concurrency=4,
                                 overlay_min_gap=0.8 )
    dog_clips = []
    for dog_pic in glob.glob( "./examples/dog*jpg" ):
        dog_video_file = vedit.gen_background_video( bgimage_file=dog_pic,
                                                     duration=random.randint( 3, 6 ) )