Dirac - A Video Codec

Created by the British Broadcasting Corporation.


dirac::GenericIntraDCBandCodec< EntropyCodec > Class Template Reference

A template class specially for coding the DC subband of Intra frames.

#include <band_codec.h>

Inheritance diagram for dirac::GenericIntraDCBandCodec< EntropyCodec >:
Collaboration diagram for dirac::GenericIntraDCBandCodec< EntropyCodec >:

Public Member Functions

 GenericIntraDCBandCodec (SubbandByteIO *subband_byteio, size_t number_of_contexts, const SubbandList &band_list)
 Constructor.
Public Member Functions inherited from dirac::GenericBandCodec< EntropyCodec >
 GenericBandCodec (SubbandByteIO *subband_byteio, size_t number_of_contexts, const SubbandList &band_list, int band_num, const bool is_intra)
 Constructor.

Protected Member Functions

void ClearBlock (const CodeBlock &code_block, CoeffArray &coeff_data)
 When coding a skipped block, propegate the predicted values for future non skipped blocks.
CoeffType GetPrediction (const CoeffArray &data, const int xpos, const int ypos) const
 Prediction of a DC value from its previously coded neighbours.
void DecodeCoeffBlock (const CodeBlock &code_block, CoeffArray &out_data)
 Decode codeblock of coefficients and perform DC prediction.
Protected Member Functions inherited from dirac::GenericBandCodec< EntropyCodec >
void CodeVal (CoeffArray &in_data, const int xpos, const int ypos, const CoeffType val)
 Code an individual quantised value and perform inverse-quantisation.
void DecodeVal (CoeffArray &out_data, const int xpos, const int ypos)
 Decode an individual quantised value and perform inverse-quantisation.
void CodeQuantIndexOffset (const int offset)
 Encode the offset for a code block quantiser.
int DecodeQuantIndexOffset ()
 Decode the offset for a code block quantiser.
void SetToVal (const CodeBlock &code_block, CoeffArray &coeff_data, const CoeffType val)
 Set a code block area to a given value.
virtual void DoWorkCode (CoeffArray &in_data)
virtual void DoWorkDecode (CoeffArray &out_data)
virtual void CodeCoeffBlock (const CodeBlock &code_block, CoeffArray &in_data)
virtual void CodeCoeff (CoeffArray &in_data, const int xpos, const int ypos)
virtual void DecodeCoeff (CoeffArray &in_data, const int xpos, const int ypos)
int ChooseFollowContext (const int bin_number) const
 A function for choosing the context for "follow bits".
int ChooseInfoContext () const
 A function for choosing the context for "information bits".
int ChooseSignContext (const CoeffArray &data, const int xpos, const int ypos) const
 A function for choosing the context for sign bits.

Additional Inherited Members

Protected Attributes inherited from dirac::GenericBandCodec< EntropyCodec >
bool m_is_intra
 Flag indicating whether the band comes from an intra picture.
int m_bnum
 variables
const Subband m_node
 the subband being coded
int m_last_qf_idx
 the quantisation index of the last codeblock
int m_qf
 quantisation value
CoeffType m_offset
 reconstruction point
bool m_nhood_nonzero
 True if neighbours non-zero.
Subband m_pnode
 the parent subband
int m_pxpos
 position of the parent coefficient
int m_pypos
bool m_parent_notzero
 True if the parent of a coeff is not zero.

Constructor & Destructor Documentation

◆ GenericIntraDCBandCodec()

template<typename EntropyCodec>
dirac::GenericIntraDCBandCodec< EntropyCodec >::GenericIntraDCBandCodec ( SubbandByteIO * subband_byteio,
size_t number_of_contexts,
const SubbandList & band_list )
inline

Creates a IntraDCBandCodec object to encode subband data

Parameters
subband_byteioinput/output for the encoded bits
number_of_contextsthe number of contexts used in the encoding process
band_listthe set of all the subbands

References dirac::GenericBandCodec< EntropyCodec >::GenericBandCodec().

Member Function Documentation

◆ ClearBlock()

template<typename EntropyCodec>
void GenericIntraDCBandCodec::ClearBlock ( const CodeBlock & code_block,
CoeffArray & coeff_data )
protectedvirtual

◆ DecodeCoeffBlock()

template<typename EntropyCodec>
void GenericIntraDCBandCodec::DecodeCoeffBlock ( const CodeBlock & code_block,
CoeffArray & out_data )
protectedvirtual

◆ GetPrediction()

template<typename EntropyCodec>
CoeffType GenericIntraDCBandCodec::GetPrediction ( const CoeffArray & data,
const int xpos,
const int ypos ) const
protected

Referenced by ClearBlock(), and DecodeCoeffBlock().


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

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