MJPEG

From Wikipedia, the free encyclopedia

Motion JPEG (M-JPEG) is an informal name for multimedia formats where each video frame or interlaced field of a digital video sequence is separately compressed as a JPEG image. It is often used in mobile appliances such as digital cameras.

Contents

[edit] Codec

Motion JPEG uses intraframe coding technology that is very similar in technology to the I-frame part of video coding standards such as MPEG-1 and MPEG-2, but does not use interframe prediction. The lack of use of interframe prediction results in a loss of compression capability, but eases video editing, since simple edits can be performed at any frame when all frames are I-frames. Video coding formats such as MPEG-2 can also be used in such an I-frame only fashion to provide similar compression capability and similar ease of editing features.

Using only intraframe coding technology also makes the degree of compression capability independent of the amount of motion in the scene, since temporal prediction is not being used. (Using temporal prediction can ordinarily substantially improve video compression capability, but makes the compression performance dependent on how well the motion compensation performs for the scene content.) Because of this, it is used in surveillance cameras which only take one frame per second, in which time there could be large amounts of change.

For Quicktime formats, Apple have defined two types of coding: MJPEG-A and MJPEG-B. MJPEG-B no longer retains valid JPEG Interchange Files within it, hence it is not possible to take a frame into a JPEG file without slightly modifying the headers.

The bitrate falls between uncompressed formats (like RGB, compression 1:1, and YCbCr, compression 1:1.5 to 1:2.5) and MPEG (1:100). Data rates in the range of 29 Mbit/s are very high quality, but also result in comparatively large file sizes.

[edit] Applications

M-JPEG is frequently used in non-linear video editing systems. Reproduction of this format at full speed requires fast JPEG decoding capability.

M-JPEG is also commonly used by IP based video cameras via HTTP streams by using the multipart/x-mixed-replace content type. This separates each image into individual HTTP replies on a specified marker. Mozilla based browsers like Netscape and Firefox have native support for viewing these streams whereas Internet Explorer does not.

The PlayStation game console has integrated M-JPEG decompression hardware in order to play in-game FMV sequences. Nintendo's Wii game console can play M-JPEG-encoded videos off an SD card using its Photo Channel. The SanDisk Sansa digital audio player plays short M-JPEG videos.

[edit] Digital cameras

Prior to the recent rise in MPEG-4 encoding in consumer devices, a progressive scan form of MJPEG also saw widespread use in e.g. the "movie" modes of Digital Still Cameras, allowing video encoding and playback through the integrated JPEG compression hardware with only a software modification. Again, the resultant quality is markedly reduced compared to MPEG compression at a similar bitrate, particularly as sound (when included) was often uncompressed PCM or low-compression (and low processor-demand) ADPCM.

To compensate and keep file sizes / transfer rates under control, frame sizes and rates, along with sound sampling rates, were kept relatively low, with very high levels of compression for each individual frame; e.g. 160x120 or 320x240 common sizes, typically at 10, 12 or 15 frames/second, with picture quality equivalent to a JPEG setting of "50" (harsher compression than used commercially in typical digital stills) and 8 kHz mono ADPCM sound.

This resulted in a very basic, but still servicable video output at a similar storage cost to MPEG (~120 kB/s video rate, ~8 kB/s audio - or approx 1 Mbit/s at "high" 320x240 resolution), but with minimal processing overheads. This user generated content was typically stored in the popular Windows AVI or Apple Quicktime MOV container files, generally viewable natively (or after installation of a simple CODEC driver) in most versions of the applicable operating system.

[edit] Criticisms

  • Unlike the video formats specified in international standards such as MPEG-2 and the format specified in the JPEG still-picture coding standard, there is no document that defines a single exact format that is universally recognized as a complete specification of "Motion JPEG" for use in all contexts. This raises compatibility concerns about file outputs from different manufacturers.
  • The format has a relatively high bit rate for the delivered quality, requiring more storage space than more modern formats for a given image quality.
  • Since the development of the original JPEG standard in the early 1990s, technology improvements have made improvements in intraframe compression possible. The JPEG organization itself has developed a new design called JPEG 2000, and other types of such technology improvements can be found in the designs of H.263v2 Annex I and MPEG-4 Part 2, which use frequency-domain prediction of transform coefficient values, and in H.264/MPEG-4 AVC, which uses spatial prediction and adaptive transform block size techniques and more sophisticated entropy coding than what was practical when the first JPEG design was developed. As a result, MJPEG is an outdated and inefficient codec, whose main advantage is low processor overhead.

[edit] See also

[edit] External links