MgzEncoder Class Reference

Low-level class to write mgz files. More...

#include <Media/MgzEncoder.H>

Inheritance diagram for MgzEncoder:
Inheritance graph
[legend]
Collaboration diagram for MgzEncoder:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 MgzEncoder (const std::string &fname, const int complev)
 Constructor.
virtual ~MgzEncoder ()
 Destructor.
virtual int close ()
 Close the file cleanly.
virtual void writeFrame (const GenericFrame &frame)
 Write a frame into the file.

Detailed Description

Low-level class to write mgz files.

You probably want to use MgzOutputStream instead, which relies on MgzEncoder internally for its implementation but offers a richer, higher-level interface. MGZ is a custom format which basically consists of just dumping raw frames into a gzip-compressed file, using zlib as the back-end compression engine. As far as MgzEncoder is concerned, frames could be of any size and any type. Applications using the encoder, however, may want to enforce that a given MGZ file only contains frames of a given size and type.

Definition at line 57 of file MgzEncoder.H.


Constructor & Destructor Documentation

MgzEncoder::MgzEncoder ( const std::string fname,
const int  complev 
)

Constructor.

Parameters:
fname the file name
complev the zlib compression level (1..9)

Definition at line 52 of file MgzEncoder.C.

References sformat().

MgzEncoder::~MgzEncoder (  )  [virtual]

Destructor.

Definition at line 70 of file MgzEncoder.C.

References close().


Member Function Documentation

int MgzEncoder::close (  )  [virtual]

Close the file cleanly.

Implements LowLevelEncoder.

Definition at line 76 of file MgzEncoder.C.

Referenced by ~MgzEncoder().

void MgzEncoder::writeFrame ( const GenericFrame frame  )  [virtual]

The documentation for this class was generated from the following files:
Generated on Sun May 8 08:43:37 2011 for iLab Neuromorphic Vision Toolkit by  doxygen 1.6.3