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

encoding class for data-to-data jpeg compression More...

#include <JPEGEncoder.h>

Inheritance diagram for icl::io::JPEGEncoder:
icl::utils::Uncopyable

Classes

struct  EncodedData
 encoded data type More...
 

Public Member Functions

 JPEGEncoder (int quality=90)
 constructor with given jpeg quality More...
 
 ~JPEGEncoder ()
 Destructor. More...
 
void setQuality (int quality)
 sets the compression quality level More...
 
const EncodedDataencode (const core::ImgBase *image)
 encodes a given core::ImgBase * (only depth8u is supported natively) More...
 
void writeToFile (const core::ImgBase *image, const std::string &filename)
 first encodes the jpeg in memory and then write the whole memory chunk to disc More...
 

Private Attributes

Data * m_data
 pimpl type More...
 

Additional Inherited Members

- Protected Member Functions inherited from icl::utils::Uncopyable
 Uncopyable ()
 Empty base constructor. More...
 

Detailed Description

encoding class for data-to-data jpeg compression

Constructor & Destructor Documentation

◆ JPEGEncoder()

icl::io::JPEGEncoder::JPEGEncoder ( int  quality = 90)

constructor with given jpeg quality

The quality value is always given in percet (1-100)

◆ ~JPEGEncoder()

icl::io::JPEGEncoder::~JPEGEncoder ( )

Destructor.

Member Function Documentation

◆ encode()

const EncodedData& icl::io::JPEGEncoder::encode ( const core::ImgBase image)

encodes a given core::ImgBase * (only depth8u is supported natively)

non-depth8u images are automatically converted before compression. This might lead to loss of data

◆ setQuality()

void icl::io::JPEGEncoder::setQuality ( int  quality)

sets the compression quality level

◆ writeToFile()

void icl::io::JPEGEncoder::writeToFile ( const core::ImgBase image,
const std::string &  filename 
)

first encodes the jpeg in memory and then write the whole memory chunk to disc

Member Data Documentation

◆ m_data

Data* icl::io::JPEGEncoder::m_data
private

pimpl type

pimpl pointer


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