Dirac - A Video Codec

Created by the British Broadcasting Corporation.


Public Member Functions | Private Member Functions | Private Attributes | List of all members
dirac::CoeffArray Class Reference

A class for wavelet coefficient data. More...

#include <wavelet_utils.h>

Inheritance diagram for dirac::CoeffArray:
Inheritance graph
[legend]
Collaboration diagram for dirac::CoeffArray:
Collaboration graph
[legend]

Public Member Functions

 CoeffArray ()
 Default constructor. More...
 
 CoeffArray (int height, int width, CompSort cs=Y_COMP)
 Constructor. More...
 
 ~CoeffArray ()
 Destructor. More...
 
const CompSortCSort () const
 Return which component is stored. More...
 
void SetCSort (const CompSort cs)
 Set the type of component being stored. More...
 
SubbandListBandList ()
 Returns the set of subbands. More...
 
const SubbandListBandList () const
 Returns the set of subbands. More...
 
void SetBandWeights (const EncoderParams &encparams, const PictureParams &pparams, const CompSort csort, const float cpd_scale_factor)
 Sets the subband weights. More...
 
- Public Member Functions inherited from dirac::TwoDArray< CoeffType >
 TwoDArray ()
 Default constructor. More...
 
 TwoDArray (const int height, const int width)
 Constructor. More...
 
 TwoDArray (const int height, const int width, CoeffType val)
 Constructor. More...
 
 TwoDArray (const TwoDArray< CoeffType > &Cpy)
 Copy constructor. More...
 
virtual ~TwoDArray ()
 Destructor. More...
 
TwoDArray< CoeffType > & operator= (const TwoDArray< CoeffType > &rhs)
 Assignment =. More...
 
bool CopyContents (TwoDArray< CoeffType > &out) const
 Copy Contents. More...
 
void Fill (CoeffType val)
 Fill contents. More...
 
void Resize (const int height, const int width)
 Resizes the array, deleting the current data.
More...
 
element_typeoperator[] (const int pos)
 Element access. More...
 
const element_typeoperator[] (const int pos) const
 Element access. More...
 
int LengthX () const
 Returns the width. More...
 
int LengthY () const
 Returns the height. More...
 
int FirstX () const
 Returns the index of the first element of a row. More...
 
int FirstY () const
 Returns the index of the first element of a column. More...
 
int LastX () const
 Returns the index of the last element of a row. More...
 
int LastY () const
 Returns the index of the first element of a column. More...
 

Private Member Functions

float PerceptualWeight (float xf, float yf, CompSort cs)
 Given x and y spatial frequencies in cycles per degree, returns a weighting value. More...
 

Private Attributes

CompSort m_csort
 
SubbandList m_band_list
 

Detailed Description

A class for encapsulating coefficient data, derived from TwoDArray..

Constructor & Destructor Documentation

◆ CoeffArray() [1/2]

dirac::CoeffArray::CoeffArray ( )
inline

Default constructor creates an empty array.

◆ CoeffArray() [2/2]

dirac::CoeffArray::CoeffArray ( int  height,
int  width,
CompSort  cs = Y_COMP 
)
inline

Contructor creates a two-D array, with specified size and colour format.

◆ ~CoeffArray()

dirac::CoeffArray::~CoeffArray ( )
inline

Member Function Documentation

◆ BandList() [1/2]

SubbandList & dirac::CoeffArray::BandList ( )
inline

References m_band_list.

◆ BandList() [2/2]

const SubbandList & dirac::CoeffArray::BandList ( ) const
inline

References m_band_list.

◆ CSort()

const CompSort & dirac::CoeffArray::CSort ( ) const
inline

References m_csort.

◆ PerceptualWeight()

float dirac::CoeffArray::PerceptualWeight ( float  xf,
float  yf,
CompSort  cs 
)
private

◆ SetBandWeights()

void dirac::CoeffArray::SetBandWeights ( const EncoderParams encparams,
const PictureParams pparams,
const CompSort  csort,
const float  cpd_scale_factor 
)

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.

◆ SetCSort()

void dirac::CoeffArray::SetCSort ( const CompSort  cs)
inline

References m_csort.

Member Data Documentation

◆ m_band_list

SubbandList dirac::CoeffArray::m_band_list
private

Referenced by BandList().

◆ m_csort

CompSort dirac::CoeffArray::m_csort
private

Referenced by CSort(), and SetCSort().


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

© 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.