Skip to main content

A Python package for generating videos from JSON specifications

Project description

VidKit

A simple and powerful Python package for generating videos from JSON configurations. VidKit makes it easy to create videos by combining images, setting durations, and adding audio tracks.

Installation

pip install vidkit

Quick Start

from vidkit import renderVideo

# Define your video configuration
config = {
    "name": "my_video",
    "format": "mp4",
    "fps": 30,
    "resolution": {
        "width": 1920,
        "height": 1080
    },
    "frames": [
        {
            "image": "frame1.jpg",
            "duration": 5
        },
        {
            "image": "frame2.jpg",
            "duration": 5
        }
    ],
    "audio": "background.mp3"
}

# Generate the video
video = renderVideo(config)

# Save to file
with open("output.mp4", "wb") as f:
    f.write(video)

Features

  • Simple JSON-based configuration
  • Support for multiple image frames
  • Audio track integration
  • Fast video generation using moviepy
  • Flexible resolution settings
  • Configurable frame rates

Configuration Options

The video configuration accepts the following parameters:

Parameter Type Description Required
name string Name of the video Yes
format string Output format (currently 'mp4') Yes
framerate number Frame rate in FPS Yes
resolution [width, height] Video dimensions in pixels Yes
frames array List of frame objects Yes
audio string Path to audio file No

Frame Object Properties

Property Type Description Required
image string Path to image file Yes
duration number Duration in seconds Yes

Requirements

  • Python >= 3.6
  • moviepy >= 2.0.0
  • Pillow >= 9.2.0
  • numpy >= 1.25.0

Contributing

Contributions are welcome! Feel free to:

  1. Fork the repository
  2. Create a feature branch
  3. Submit a Pull Request

License

This project is licensed under the MIT License - see the LICENSE file for details.

Author

Created by Carter Stach (@SpyC0der77)

Support

If you encounter any issues or have questions, please open an issue on GitHub.

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

vidkit-0.1.2.tar.gz (5.0 kB view details)

Uploaded Source

Built Distribution

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

vidkit-0.1.2-py3-none-any.whl (4.9 kB view details)

Uploaded Python 3

File details

Details for the file vidkit-0.1.2.tar.gz.

File metadata

  • Download URL: vidkit-0.1.2.tar.gz
  • Upload date:
  • Size: 5.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.0

File hashes

Hashes for vidkit-0.1.2.tar.gz
Algorithm Hash digest
SHA256 69f8ac5efb6c2121ef4dc174052e306b53c5b6db9199c2f3f1ba560bee51ba40
MD5 658f530394283058a6631d0cd4d446d4
BLAKE2b-256 a76957b6050543edae317b2b9a2fdf87244617b04ad0522a454af82556cee98d

See more details on using hashes here.

File details

Details for the file vidkit-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: vidkit-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 4.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.0

File hashes

Hashes for vidkit-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 39dccd06261bb19f30cebdb14a3af3fd358589a384c58797498be9f011f19c03
MD5 14b798df1f14513bd85ad656125b31f1
BLAKE2b-256 653d3ab34ca97efd1bc35973a5e6358fa115465c38059a57f9b318f7530bb8ca

See more details on using hashes here.

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