Loading...
Searching...
No Matches
DiJPEGPlugin Class Reference

Implementation of a JPEG plugin for the dcmimgle/dcmimage library. More...

Inheritance diagram for DiJPEGPlugin:

## Public Member Functions

| DiJPEGPlugin ()
| constructor
virtual | ~DiJPEGPlugin ()
| destructor
virtual int | write (DiImage *image, FILE *stream, const unsigned long frame=0) const
| write given image to a file stream (JPEG format)
void | setQuality (const unsigned int quality)
| set quality value for JPEG compression
void | setSampling (const E_SubSampling sampling)
| set (sub) sampling for JPEG compression.
void | outputMessage (void *arg) const
| callback function used to report IJG warning messages and the like.
Public Member Functions inherited from DiPluginFormat
virtual | ~DiPluginFormat ()
| destructor (virtual)

## Static Public Member Functions

static OFString | getLibraryVersionString ()
| get version information of the TIFF library.

## Private Attributes

unsigned int | Quality
| quality value (0..100, in percent), default: 75
E_SubSampling | Sampling
| (sub) sampling: ESS_444, ESS_422 (default), ESS_411

## Additional Inherited Members

Protected Member Functions inherited from DiPluginFormat
| DiPluginFormat ()
| constructor (protected)

## Detailed Description

Implementation of a JPEG plugin for the dcmimgle/dcmimage library.

## Member Function Documentation

## getLibraryVersionString()

OFString DiJPEGPlugin::getLibraryVersionString | ( |  | ) |

static

get version information of the TIFF library.

Typical output format: "IJG, Version 6b 27-Mar-1998 (modified)"

Returns
  name and version number of the TIFF library

## outputMessage()

void DiJPEGPlugin::outputMessage | ( | void * | arg | ) | const

callback function used to report IJG warning messages and the like.

Should not be called by user code directly.

Parameters

  arg | opaque pointer to JPEG compress structure

## setQuality()

void DiJPEGPlugin::setQuality | ( | const unsigned int | quality | ) |

set quality value for JPEG compression

Parameters

  quality | quality value (0..100, in percent)

## setSampling()

void DiJPEGPlugin::setSampling | ( | const E_SubSampling | sampling | ) |

set (sub) sampling for JPEG compression.

Only used for color images. ESS_444 means no sub-sampling, ESS_422 horizontal subsampling of chroma components and ESS_422 horizontal and vertical subsampling of chroma components.

Parameters

  sampling | sampling (valid values: ESS_444, ESS_422 or ESS_411)

## write()

virtual int DiJPEGPlugin::write | ( | DiImage * | image,
|  | FILE * | stream,
|  | const unsigned long | frame = 0 ) const

virtual

write given image to a file stream (JPEG format)

Parameters

  image | pointer to DICOM image object to be written
  stream | stream to which the image is written (open in binary mode!)
  frame | index of frame used for output (default: first frame = 0)

Returns
  true if successful, false otherwise

Implements DiPluginFormat.

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

- dcmjpeg/include/dcmtk/dcmjpeg/dipijpeg.h

Generated on for DCMTK Version 3.7.0 by Doxygen 1.15.0