Skip to main content
100%

Flask app for video streaming over http

✓ Published0🌍 Public
VValIlya
Last edited Mar 16, 2020
Created on Mar 16, 2020

A Flask app streams video files over HTTP by serving byte-range requests, enabling clients to seek and play MP4 and MKV videos without downloading the entire file. It lists available videos from a specified directory on the index page, then uses custom regex route converters to match file extensions. The `get_chunk` function reads partial file content using Python's `os.stat` and `f.seek`, while response headers like `Accept-Ranges` and `Content-Range` are added via Flask's `Response` object to support HTTP range requests.

AI-generated description

Similar vizzes