Need advice on where to start with video downloads #3077
Unanswered
ShovelJockey
asked this question in
Q&A
Replies: 1 comment 2 replies
-
You could use something like https://videojs.com/ in the browser. On the backend side, you would need to support HTTP range requests support. You could have a look at this: #3047 |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Summary
I have created an axum server that remotely manages the starting/shutdown of a motion detection triggered camera.
My next step is to have the client also be able to download recorded videos from server but am not quite sure how best to get this done with axum. Seems like a reading the file to a stream then returning a response with a stream body similar to some of the examples here would work with the client reading the stream to a file or passing it to video player directly?
But have also seen protocols like HLS being suggested, tower-http functions for serving files alongside vague mentions of using websockets without much specific detail. Ideally looking for something that isn't especially complex while still quite performant that would be flexible enough for a client to be able to save to file or encode and play without needing to save, would really appreciate some advice from someone more experienced with working with media in rust.
These videos are generally quite small in size (between 1-30Mb mostly) and currently am using mp4 format.
axum version
0.7.5
Beta Was this translation helpful? Give feedback.
All reactions