Dirac Video Codec

# Dirac - A Video Codec

Created by the British Broadcasting Corporation.

# dirac::PictureByteIO Class Reference

A compressed picture in Dirac bytestream format.

`#include <picture_byteio.h>`

Inheritance diagram for dirac::PictureByteIO:
[legend]
Collaboration diagram for dirac::PictureByteIO:
[legend]

List of all members.

## Public Member Functions

- PictureByteIO (PictureParams &frame_params, int frame_num)
    Constructor.
- PictureByteIO (PictureParams &frame_params, const ParseUnitByteIO &parseunit_byteio)
    Constructor.
- virtual ~PictureByteIO ()
    Destructor.
- void CollateByteStats (DiracByteStats &dirac_byte_stats)
    Gathers byte stats on the picture data.
- bool Input ()
    Inputs data from Dirac stream-format.
- void Output ()
    Outputs picture values to Dirac stream-format.
- const std::string GetBytes ()
    Gets string containing coded bytes.
- int GetSize () const
    Gets size (in bytes).
- ParseUnitType GetType () const
    Gets parse-unit type.
- int IsRef () const
    Returns true is picture in Reference picture.
- int IsNonRef () const
    Returns true is picture in Non-Reference picture.
- int NumRefs () const
    Gets parse-unit type.
- bool IsIntra () const
    Returns true is picture is Intra picture.
- bool IsInter () const
    Returns true is picture is Inter picture.
- void SetMvData (MvDataByteIO *mv_data)
- void SetTransformData (TransformByteIO *transform_data)

## Private Member Functions

- unsigned char CalcParseCode () const
    Calculates parse-code based on picture parameters.
- void InputReferencePictures ()
    Reads reference-picture data.
- void InputRetiredPicture ()
    Reads retired picture number.
- void SetPictureType ()
    Calculates picture-type (eg INTRA/INTER) of picture.
- void SetReferenceType ()
    Calculates reference-type of picture.
- void SetEntropyCodingFlag ()
    Sets the entropy coding flag in the picture parameters.

## Private Attributes

- PictureParams & m_frame_params
    Picture parameters.
- int m_frame_num
    Picture number.
- MvDataByteIO * m_mv_data
    MV data.
- TransformByteIO * m_transform_data
    Transform data.

## Constructor & Destructor Documentation

dirac::PictureByteIO::PictureByteIO | ( | PictureParams & | frame_params,
|  | int | frame_num |
| ) |  |  |

Parameters:

  | frame_params | Picture parameters
  | frame_num | Picture number

dirac::PictureByteIO::PictureByteIO | ( | PictureParams & | frame_params,
|  | const ParseUnitByteIO & | parseunit_byteio |
| ) |  |  |

Parameters:

  | frame_params | Destination of data
  | parseunit_byteio | Source of data

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

## Member Function Documentation

void dirac::PictureByteIO::CollateByteStats | ( | DiracByteStats & | dirac_byte_stats | ) | `[virtual]`

Parameters:

  | dirac_byte_stats | Stat container

Reimplemented from dirac::ParseUnitByteIO.

bool dirac::PictureByteIO::Input | ( |  | ) |

Reimplemented from dirac::ParseUnitByteIO.

void dirac::PictureByteIO::Output | ( |  | ) |

const std::string dirac::PictureByteIO::GetBytes | ( |  | ) | `[virtual]`

Reimplemented from dirac::ParseUnitByteIO.

int dirac::PictureByteIO::GetSize | ( |  | ) | const`[virtual]`

Reimplemented from dirac::ParseUnitByteIO.

ParseUnitType dirac::PictureByteIO::GetType | ( |  | ) | const`[inline, virtual]`

Reimplemented from dirac::ParseUnitByteIO.

References dirac::PU_PICTURE.

int dirac::PictureByteIO::IsRef | ( |  | ) | const`[inline]`

References dirac::ParseUnitByteIO::GetParseCode().

int dirac::PictureByteIO::IsNonRef | ( |  | ) | const`[inline]`

References dirac::ParseUnitByteIO::GetParseCode().

int dirac::PictureByteIO::NumRefs | ( |  | ) | const`[inline]`

References dirac::ParseUnitByteIO::GetParseCode().

Referenced by IsInter(), and IsIntra().

bool dirac::PictureByteIO::IsIntra | ( |  | ) | const`[inline]`

References dirac::ParseUnitByteIO::IsPicture(), and NumRefs().

bool dirac::PictureByteIO::IsInter | ( |  | ) | const`[inline]`

References dirac::ParseUnitByteIO::IsPicture(), and NumRefs().

void dirac::PictureByteIO::SetMvData | ( | MvDataByteIO * | mv_data | ) | `[inline]`

References m_mv_data.

void dirac::PictureByteIO::SetTransformData | ( | TransformByteIO * | transform_data | ) | `[inline]`

References m_transform_data.

unsigned char dirac::PictureByteIO::CalcParseCode | ( |  | ) | const`[private, virtual]`

Returns:
  Char bit-set

Reimplemented from dirac::ParseUnitByteIO.

void dirac::PictureByteIO::InputReferencePictures | ( |  | ) | `[private]`

void dirac::PictureByteIO::InputRetiredPicture | ( |  | ) | `[private]`

void dirac::PictureByteIO::SetPictureType | ( |  | ) | `[private]`

void dirac::PictureByteIO::SetReferenceType | ( |  | ) | `[private]`

void dirac::PictureByteIO::SetEntropyCodingFlag | ( |  | ) | `[private]`

## Member Data Documentation

PictureParams& dirac::PictureByteIO::m_frame_params`[private]`

int dirac::PictureByteIO::m_frame_num`[private]`

MvDataByteIO* dirac::PictureByteIO::m_mv_data`[private]`

Referenced by SetMvData().

TransformByteIO* dirac::PictureByteIO::m_transform_data`[private]`

Referenced by SetTransformData().

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

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