DEV Community

Cover image for Streaming live video feed on a website with a MJPEG server
Piotr Maliński
Piotr Maliński

Posted on

Streaming live video feed on a website with a MJPEG server

Generic IP cameras often offer a simple MJPEG streaming that allows embedding a live view from the camera on a website. However when that's not available or you want to stream something different (desktop view, machine vision camera or some pre-recorded video clip) then you need your own MJPEG server.

There is a lot of example on the web, and by now MJPEG is not the best choice in terms of bandwidth/quality but it's simple...

So let's take a look at a simple server from Github: https://github.com/bootrino/maryjane

This simple server will stream contents of a JPEG file. To make it a video we have to use some other app to constantly update said file. This can be done with ffmpeg to stream a video clip or your desktop. Or some other source, like a machine vision camera and it SDK allowing capturing and saving frames.

Examples and more info on my blog:

https://rk.edu.pl/en/streaming-live-video-feed-on-a-website-with-a-mjpeg-server/

Top comments (0)