# Dirac - A Video Codec

Created by the British Broadcasting Corporation.

# dirac::WaveletTransform Class Reference

A class to do wavelet transforms. More...

`#include <wavelet_utils.h>`

Collaboration diagram for dirac::WaveletTransform:

[legend]
List of all members.

## Public Member Functions

- WaveletTransform (int d=4, WltFilter f=DAUB97)
    Constructor.
- virtual ~WaveletTransform ()
    Destructor.
- void Transform (const Direction d, PicArray &pic_data)
    Transforms the data to and from the wavelet domain.
- SubbandList & BandList ()
    Returns the set of subbands.
- const SubbandList & BandList () const
    Returns the set of subbands.
- void SetBandWeights (const float cpd, const FrameSort &fsort, const ChromaFormat &cformat, const CompSort csort)
    Sets the subband weights.
- ValueType GetMeanDCVal () const
    Return the expected DC band value assuming a mid-grey picture (mean val=512).

## Private Member Functions

- WaveletTransform (const WaveletTransform &cpy)
    Private, bodyless copy constructor: class should not be copied.
- WaveletTransform & operator= (const WaveletTransform &rhs)
    Private, bodyless copy operator=: class should not be assigned.
- float PerceptualWeight (float xf, float yf, CompSort cs)
    Given x and y spatial frequencies in cycles per degree, returns a weighting value.

## Private Attributes

- SubbandList m_band_list
- int m_depth
    Depth of the transform.
- WltFilter m_filt_sort
    The filter set to be used.
- VHFilter * m_vhfilter
    A class to do the filtering required.

## Classes

- class PredictStep97
    Class to do two-tap prediction lifting step for Daubechies (9,7). More...
- class PredictStepFourTap
    Class to do symmetric four-tap prediction lifting step. More...
- class PredictStepShift
    Class to do two-tap prediction lifting step. More...
- class UpdateStep97
    Class to do two-tap update lifting step for Daubechies (9,7). More...
- class UpdateStepFourTap
    Class to do symmetric four-tap update lifting step. More...
- class UpdateStepShift
    Class to do two-tap updating lifting step. More...
- class VHFilter
    A virtual parent class to do vertical and horizontal splitting with wavelet filters. More...
- class VHFilter13_5
    An extension of Approx9_7, with a better low-pass filter but more computation. More...
- class VHFilter5_3
    Class to do (5,3) wavelet filtering operations. More...
- class VHFilterApprox9_7
    Class to do an approximation to Daubechies (9,7) but with just two lifting steps. More...
- class VHFilterDaub9_7
    Class to do Daubechies (9,7) filtering operations. More...

## Detailed Description

A class to do forward and backward wavelet transforms by iteratively splitting or merging the lowest frequency band.

## Constructor & Destructor Documentation

dirac::WaveletTransform::WaveletTransform | ( | int | d = `4`,
|  | WltFilter | f = `DAUB97` |
| ) |  |  |

virtual dirac::WaveletTransform::~WaveletTransform | ( |  | ) | `[virtual]`

dirac::WaveletTransform::WaveletTransform | ( | const WaveletTransform & | cpy | ) | `[private]`

## Member Function Documentation

const SubbandList& dirac::WaveletTransform::BandList | ( |  | ) | const`[inline]`

SubbandList& dirac::WaveletTransform::BandList | ( |  | ) | `[inline]`

ValueType dirac::WaveletTransform::GetMeanDCVal | ( |  | ) | const

WaveletTransform& dirac::WaveletTransform::operator= | ( | const WaveletTransform & | rhs | ) | `[private]`

float dirac::WaveletTransform::PerceptualWeight | ( | float | xf,
|  | float | yf,
|  | CompSort | cs |
| ) |  |  | `[private]`

void dirac::WaveletTransform::SetBandWeights | ( | const float | cpd,
|  | const FrameSort & | fsort,
|  | const ChromaFormat & | cformat,
|  | const CompSort | csort |
| ) |  |  |

Sets perceptual weights for the subbands. Takes into account both perceptual factors (weight noise less at higher spatial frequencies) and the scaling needed for the wavelet transform.

Parameters:

  | cpd | perctual factor - the number of cycles per degree
  | fsort | the frame sort (I, L1 or L2)
  | cformat | the chroma format
  | csort | the component type (Y, U or V)

void dirac::WaveletTransform::Transform | ( | const Direction | d,
|  | PicArray & | pic_data |
| ) |  |  |

Transforms the data to and from the wavelet domain.

Parameters:

  | d | the direction of the transform
  | pic_data | the data to be transformed

## Member Data Documentation

SubbandList dirac::WaveletTransform::m_band_list`[private]`

int dirac::WaveletTransform::m_depth`[private]`

WltFilter dirac::WaveletTransform::m_filt_sort`[private]`

VHFilter* dirac::WaveletTransform::m_vhfilter`[private]`

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

- wavelet_utils.h

© 2004 British Broadcasting Corporation. Dirac code licensed under the Mozilla Public License (MPL) Version 1.1.
HTML documentation generated by Dimitri van Heesch's excellent Doxygen tool.