Image Component Library (ICL)
Public Member Functions | Private Attributes | List of all members
icl::io::OpenCVVideoWriter Class Reference

#include <OpenCVVideoWriter.h>

Inheritance diagram for icl::io::OpenCVVideoWriter:
icl::io::ImageOutput icl::io::ImageCompressor icl::utils::Uncopyable

Public Member Functions

 OpenCVVideoWriter (const std::string &filename, const std::string &fourcc, double fps, utils::Size frame_size, int frame_color=1)
 Creates a new videowriter with given filename. More...
 
 ~OpenCVVideoWriter ()
 Destructor. More...
 
void write (const core::ImgBase *image)
 writes the next image More...
 
virtual void send (const core::ImgBase *image)
 wraps write to implement ImageOutput interface More...
 
OpenCVVideoWriteroperator<< (const core::ImgBase *image)
 as write but in stream manner More...
 
- Public Member Functions inherited from icl::io::ImageOutput
virtual ~ImageOutput ()
 virtual destructor More...
 
virtual CompressionSpec getCompression () const
 provide the protectedly inherited image compressor options here More...
 
virtual void setCompression (const CompressionSpec &spec)
 provide the protectedly inherited image compressor options here More...
 

Private Attributes

CvVideoWriter * writer
 OpenCV VideoWriter struct. More...
 

Additional Inherited Members

- Protected Member Functions inherited from icl::io::ImageCompressor
Header uncompressHeader (const icl8u *compressedData, int len)
 only decodes an image header More...
 
Header createHeader (const core::ImgBase *image, bool skipMetaData)
 creates a header for a given image (not data will be null) More...
 
 ImageCompressor (const CompressionSpec &spec=CompressionSpec("none"))
 Creates an image Compressor with given compression mode. More...
 
 ~ImageCompressor ()
 Destructor. More...
 
virtual void setCompression (const CompressionSpec &spec)
 string based interface for setting the compression mode More...
 
virtual CompressionSpec getCompression () const
 can be implemented for returning the current compression mode More...
 
utils::Time pickTimeStamp (const icl8u *compressedData)
 this can help to find out wheter the data is new and must be encoded More...
 
const CompressedData compress (const core::ImgBase *image, bool skipMetaData=false)
 encodes a given image into the compressed code More...
 
const core::ImgBaseuncompress (const icl8u *compressedData, int len, core::ImgBase **dst=0)
 decodes the given byte segment More...
 
- Protected Member Functions inherited from icl::utils::Uncopyable
 Uncopyable ()
 Empty base constructor. More...
 

Constructor & Destructor Documentation

◆ OpenCVVideoWriter()

icl::io::OpenCVVideoWriter::OpenCVVideoWriter ( const std::string &  filename,
const std::string &  fourcc,
double  fps,
utils::Size  frame_size,
int  frame_color = 1 
)

Creates a new videowriter with given filename.

Parameters
filenamethe filename to write to
fourccthis is translated into an instance of FOURCC possible is: PIM1 (for mpeg 1) MJPG (for motion jepg) MP42 (for mpeg 4.2) DIV3 (for mpeg 4.3) DIVX (for mpeg 4) U263 (for H263 codec) I263 (for H263I codec) FLV1 (for FLV1 code) on linux: IYUV for IYUV codec ?? on windows: "" for open dialog
fpsframes per second
frame_sizesize of the frames to be written out
frame_colorcurrently only supported on windows 0 for greyscale else color

◆ ~OpenCVVideoWriter()

icl::io::OpenCVVideoWriter::~OpenCVVideoWriter ( )

Destructor.

Member Function Documentation

◆ operator<<()

OpenCVVideoWriter& icl::io::OpenCVVideoWriter::operator<< ( const core::ImgBase image)

as write but in stream manner

◆ send()

virtual void icl::io::OpenCVVideoWriter::send ( const core::ImgBase image)
inlinevirtual

wraps write to implement ImageOutput interface

Implements icl::io::ImageOutput.

◆ write()

void icl::io::OpenCVVideoWriter::write ( const core::ImgBase image)

writes the next image

Member Data Documentation

◆ writer

CvVideoWriter* icl::io::OpenCVVideoWriter::writer
private

OpenCV VideoWriter struct.


The documentation for this class was generated from the following file: