WebVTT reader, writer and segmenter
Project description
webvtt-py is a Python module for reading/writing WebVTT caption files. It also features caption segmentation useful when captioning HLS videos.
Requires Python 3.3+.
Documentation is available at http://webvtt-py.readthedocs.io.
Installation
$ pip install webvtt-py
Usage
from webvtt import WebVTT
webvtt = WebVTT().read('captions.vtt')
for c in webvtt.captions:
print(c.start)
print(c.end)
print(c.text)
Segmenting for HLS
from webvtt import WebVTTSegmenter
WebVTTSegmenter().segment('captions.vtt', 'output/path')
License
Licensed under the MIT License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
webvtt-py-0.2.0.zip
(10.4 kB
view details)
Built Distribution
File details
Details for the file webvtt-py-0.2.0.zip
.
File metadata
- Download URL: webvtt-py-0.2.0.zip
- Upload date:
- Size: 10.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 15bcd67c58ecb95a344a4872fbc892a407b570355b7d930fe5df86082ace46d3 |
|
MD5 | 6c3086b8e9d6c24c0458dcfb579aad52 |
|
BLAKE2b-256 | fb7bc7807510c8a941f23cb0892f993671e69973a2e7cc313e8c6f93eda36475 |
File details
Details for the file webvtt_py-0.2.0-py3-none-any.whl
.
File metadata
- Download URL: webvtt_py-0.2.0-py3-none-any.whl
- Upload date:
- Size: 8.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 72aa01a9ee7bd5899ea2b525ed71847160dd57f63133f7b7f47214bba6529409 |
|
MD5 | 5b4d6cf0f4b9474623db783e28e0f4bb |
|
BLAKE2b-256 | 9ef7f298d34931e1add7799e05fd7d89d50a40eee6555d4ec6488f10e4792603 |