Skip to main content

A command line tool for creating video preview thumbnails images.

Project description

pyvideothumbnailer

Pyhton Video Thumbnailer is a command line tool for creating video preview thumbnails. It can be used to create preview images of individual video files, videos located in a directory and optionally its subdirectories. It is based on PyAV, MediaInfo and PIL/Pillow.

Installation

Pyhton Video Thumbnailer has the following dependencies:

Python Video Thumbnailer can be installed from PyPI using the Python Package Installer:

python3 -m pip install pyvideothumbnailer

As of Ubuntu 22.04 LTS (Jammy Jellyfish), Ubuntu users can alternatively install a DEB package from this Ubuntu PPA.

sudo add-apt-repository ppa:haraldhetzner/ppa
sudo apt update
sudo apt install python3-pyvideothumbnailer

The optional configuration file .pyvideothumbnailer.conf needs to be placed in the user's home directory.

Usage

Python Video Thumbnailer has meaningful defaults. So you can just start creating your first preview thumbnails image of an individual video file by invoking:

pyvideothumbnailer [VIDEO FILE]

or to create thumbnails of all video files located in the current working directory:

pyvideothumbnailer

or to create thumbnails of all video files located in a directory:

pyvideothumbnailer [DIRECTORY CONTAINING VIDEOS]

or in case that you want to create previews of videos in subdirectories as well:

pyvideothumbnailer --recursive [DIRECTORY CONTAINING VIDEOS]

Examples

Here are two examples how it works creating preview thumbmnails of Big Buck Bunny.

Using defaults:

pyvideothumbnailer bbb_sunflower_1080p_60fps_normal.mp4

bbb_sunflower_1080p_60fps_normal_defaults mp4

White header font on black background, DejaVuSans TrueType font instead of the built-in font, adding a comment at the bottom of the header, custom preview thumbnails image width and 5 x 4 preview thumbnails:

pyvideothumbnailer --background-color black --header-font-color white --header-font DejaVuSans.ttf --timestamp-font DejaVuSans.ttf --comment-text "Created with pyvideothumbnailer" --width 1024 --columns 5 --rows 4 bbb_sunflower_1080p_60fps_normal.mp4

bbb_sunflower_1080p_60fps_normal mp4_example5

Documentation

Visit the wiki page for more comprehensive information on installation and usage.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyvideothumbnailer-2.0.4.tar.gz (16.8 kB view hashes)

Uploaded Source

Built Distribution

pyvideothumbnailer-2.0.4-py3-none-any.whl (15.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page