Skip to main content

MJPEG Video

Motion JPEG (MJPEG) is just a sequence of JPEG images concatenated into one stream. There's no inter-frame compression — every frame is a standalone JPEG. That makes it dramatically cheaper to decode than H.264/H.265 (no motion vectors, no reference frame management) and a perfect fit for embedded video playback.

MJPEG content can come from anywhere the device can read bytes from — an SD card, an embedded resource, or a network stream.

How it works

Because MJPEG is just JPEGs end-to-end, playback is straightforward — read the next JPEG from the stream, decode with the image decoder, draw it to the graphics surface, repeat at the desired frame rate.

The codec driver in the TinyCLR-Drivers repository handles the frame-boundary parsing and provides a higher-level read API on top of this base pattern.

See also

  • Image Decoders — decode individual JPEG frames into bitmaps
  • Graphics — draw decoded frames to the display
  • File System — load MJPEG files from SD card or USB drive