Skip to main content

Add text to a video file

Project description

vidtoolz-add-text

PyPI Changelog Tests License

Add text to a video file

Demo

Installation

First install vidtoolz.

pip install vidtoolz

Then install this plugin in the same environment as your vidtoolz application.

vidtoolz install vidtoolz-add-text

Usage

type vid addtext --help to get help

usage: vid addtext [-h] [-t TEXT] [-mt MULTI_TEXT] [-o OUTPUT]
                   [-p {top-left,top-right,bottom-left,bottom-right,center,bottom}]
                   [-st START_TIME] [-et END_TIME] [-f FONTSIZE]
                   [-pad PADDING] [-d DURATION]
                   main_video

Add text to a video file

positional arguments:
  main_video            Path to the main video file.

optional arguments:
  -h, --help            show this help message and exit
  -t TEXT, --text TEXT  Text to write
  -mt MULTI_TEXT, --multi-text MULTI_TEXT
                        Multi-text in format "text,start,duration". Can be
                        used multiple times. ex "hello,1:20,10"
  -o OUTPUT, --output OUTPUT
                        Output video file name (default: None)
  -p {top-left,top-right,bottom-left,bottom-right,center,bottom}, --position {top-left,top-right,bottom-left,bottom-right,center,bottom}
                        Position of the text (default: bottom)
  -st START_TIME, --start-time START_TIME
                        Start time when text should appear: (default: 0)
  -et END_TIME, --end-time END_TIME
                        End time when text should disappear. (default: None)
  -f FONTSIZE, --fontsize FONTSIZE
                        Fontsize (default: 50)
  -pad PADDING, --padding PADDING
                        Padding (default: 50)
  -d DURATION, --duration DURATION
                        Duration in seconds (default: 4)

Development

To set up this plugin locally, first checkout the code. Then create a new virtual environment:

cd vidtoolz-add-text
python -m venv venv
source venv/bin/activate

Now install the dependencies and test dependencies:

pip install -e '.[test]'

To run the tests:

python -m pytest

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

vidtoolz_add_text-0.4.0.tar.gz (9.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

vidtoolz_add_text-0.4.0-py3-none-any.whl (9.4 kB view details)

Uploaded Python 3

File details

Details for the file vidtoolz_add_text-0.4.0.tar.gz.

File metadata

  • Download URL: vidtoolz_add_text-0.4.0.tar.gz
  • Upload date:
  • Size: 9.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for vidtoolz_add_text-0.4.0.tar.gz
Algorithm Hash digest
SHA256 0a7ad1ce06c474312e7cb5ab5f8e231f25c214f25d26349264068c07d3068c9f
MD5 50906379d604135e597d5dac735100a6
BLAKE2b-256 6c2726a2406968c894cefac882df0cda3d295108c1b5c007d5aef1aa3792e6a8

See more details on using hashes here.

Provenance

The following attestation bundles were made for vidtoolz_add_text-0.4.0.tar.gz:

Publisher: publish.yml on sukhbinder/vidtoolz-add-text

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file vidtoolz_add_text-0.4.0-py3-none-any.whl.

File metadata

File hashes

Hashes for vidtoolz_add_text-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c43deffe664111c90dd27e8756f03b3e46a48f1ecd6bc275949c86ea12002b8a
MD5 508f40df964ddef680f4eed87c4afac9
BLAKE2b-256 50682ea3ecd2b252ee5e4a533b07053cd90b17f3b3c2bfc0603ad2cc19cc587f

See more details on using hashes here.

Provenance

The following attestation bundles were made for vidtoolz_add_text-0.4.0-py3-none-any.whl:

Publisher: publish.yml on sukhbinder/vidtoolz-add-text

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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