Skip to main content

Create thumbnail spritesheet from mp4 media files

Project description

msprites, media thumbnail sprites, multipule thumbnail spirtes

Requirements:

1. FFmpeg
2. ImageMagick Montage

Steps:

1. Extract images using ffmpeg. You can configure size of image and image rate per second(IPS)
2. Convert Image in spirtesheet of grid ROWSxCOLS
3. Create a webvtt file of spritesheet images

Recomanded Values for IPS: 1 0.50: 1 image every 2 seconds) 0.25: 1 image in every 4 second 0.20: 1 image in every 5 second 0.10: 1 image in every 10 second 0.05: 1 image in every 20 second

It uses temp folder for storage. for persistence storage move these different folder or location.

Installation pip install msprites

How to use:

import os
from msprites import Settings as SpriteSetting
from msprites import MontageSprites

SpriteSetting.load(ips=0.50)
sprite = MontageSprites.from_media(
    path="..SampleVideo_360x240_20mb.mp4",create_webvtt=True
)

print(sprite.dir.name)
for filename in os.listdir(sprite.dir.name):
    print(filename)

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

msprites-1.0.8.tar.gz (4.0 kB view details)

Uploaded Source

Built Distribution

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

msprites-1.0.8-py3-none-any.whl (6.9 kB view details)

Uploaded Python 3

File details

Details for the file msprites-1.0.8.tar.gz.

File metadata

  • Download URL: msprites-1.0.8.tar.gz
  • Upload date:
  • Size: 4.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.7.6

File hashes

Hashes for msprites-1.0.8.tar.gz
Algorithm Hash digest
SHA256 6f72ec4b8eb772df65552f7bae0bebe29b238a46a45e3444f1015694c629a7a6
MD5 c3f7fd9f93c114520ca106ba4579ddaf
BLAKE2b-256 2bb62ecc6f37618bb49b7e6dbd40c8515ec30b1ce0287875b1a028aee95f0681

See more details on using hashes here.

File details

Details for the file msprites-1.0.8-py3-none-any.whl.

File metadata

  • Download URL: msprites-1.0.8-py3-none-any.whl
  • Upload date:
  • Size: 6.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.7.6

File hashes

Hashes for msprites-1.0.8-py3-none-any.whl
Algorithm Hash digest
SHA256 8468eab9c39cfb5acbdbdd74bcd9ed68267ac653456699414075c42cfd88c79f
MD5 7b75282fa225e7f7c17b7f2b162d075b
BLAKE2b-256 9490d66b47a5442ca9c7be7c5ab58295a70725ec6befdc16699d7268d3d4ebd4

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