GithubHelp home page GithubHelp logo

Comments (4)

miguelgrinberg avatar miguelgrinberg commented on June 26, 2024

This is a Motion JPEG stream, which is a very limited form of video streaming. How a stop/restart is handled really depends on how the different browsers implement their Motion JPEG players. I would suggest that instead of stopping the stream you keep the stream running and send a repeat frame, so that it looks like the stream stopped. A real stop and resume will need to be tested on all browsers to make sure it is handled well.

from flask-video-streaming.

donskytech avatar donskytech commented on June 26, 2024

Oh, so the idea is not to stop the generator stream but show a repeat frame!
Yeah, sounds reasonable.
Thanks!

OFF-TOPIC:
I would like to ask something not related, I just don't know where to reach you.

I am doing a lot of IoT projects and I find WebSocket(Flask-SocketIO, Flask-Sock) to be a little over the top and looking for a simpler solution like Server-Sent-Events.

Do you happen to have an idea how to best do this in a Flask application running on a Rasberry Pi?

I actually have been evangelizing your MicroDot framework (in MicroPython) by doing loT projects with it and doing my best to write good blog content.

The reality is, I could not find enough solutions for both Flask and MicroDot.

Sorry to hijack this thread, please feel free to let me know where is the proper forum.

from flask-video-streaming.

miguelgrinberg avatar miguelgrinberg commented on June 26, 2024

Thanks for blogging about microdot! I have seen some of your posts already, good stuff!

If you are looking for SSE in Microdot that is not available yet, but it is in my todo list to implement at some point. The WebSocket implementation in microdot is fairly simple and easy to use, and it also works when using microdot in standard Python, without any code changes. It does not work with Flask, however.

from flask-video-streaming.

donskytech avatar donskytech commented on June 26, 2024

Thanks for the kind words!

from flask-video-streaming.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.