Overview of Motion JPEG2000

Motion JPEG2000 is an extension of the still image JPEG2000 image format that is designed for storing animations. A Motion JPEG2000 file (MJ2) consists of a collection of frames. Each frame is an independent JPEG2000 image, and like JPEG2000 images, each frame may be made up of one or more components (bands or channels of data). The individual frame components may also be composed of tiles or contain regions.

The Motion JPEG2000 format offers several features that make it an excellent choice for data storage in scientific, security, and research arenas:

You can create and play Motion JPEG2000 (MJ2) files in IDL using the IDLffMJPEG2000 object. This section describes how to create and play your own MJ2 files. In brief, an IDLffMJPEG2000 object can open an MJ2 file (identified by a Filename argument) for playback or creation based on the value of the WRITE property. When you create (write) a file, you will use the IDLffMJPEG2000::SetData method to add frames, components or tiles of data to the file. When the animation is complete, call the IDLffMJPEG2000::Commit method to close the file. See Creating a Motion JPEG2000 Animation for details.

Note
The same IDLffMJPEG2000 object cannot be used to both write and read an MJ2 file. You can write a file with one object (where WRITE=1), but you must create a separate object (where WRITE=0, the default) in order to read or play the new MJ2 file.

The IDLffMJPEG2000 object supports sequential and random playback. To create a sequential playback, you will use a group of methods to start the reading process, retrieve the frame, release the frame and stop the reading process. These methods are described in Playing a Motion JPEG2000 Animation. If you want to control the playback rate, you will need to include some sort of timer mechanism as described in Controlling the Playback Rate.

When creating and playing an MJ2 file, IDL uses an internal background processing thread to compress or decompress frames into a frame buffer. Depending upon the size and complexity of the frame, creation or playback may be delayed if frame compression or decompression takes longer than the associated method call. To avoid such a delay, modify the FRAME_BUFFER_LENGTH property as described in High Speed MJ2 Reading and Writing.

Sample Motion JPEG2000 Player and Writer

The IDL distribution includes a sample MJ2 player and an MJ2 writer as follows:

Supported Platforms

See Feature Support by Operating System (Installation and Licensing Guide) for supported platform details.