# Dirac - A Video Codec

Created by the British Broadcasting Corporation.

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

Parameters for initialising picture class objects.

`#include <common.h>`

Collaboration diagram for dirac::PictureParams:
[legend]

## Public Member Functions
| PictureParams ()
| Default constructor. More...
| PictureParams (const ChromaFormat &cf, int xlen, int ylen, unsigned int luma_depth, unsigned int chroma_depth)
| Constructor. More...
| PictureParams (const ChromaFormat &cf, const PictureSort &fs)
| Constructor. More...
| PictureParams (const SourceParams &sparams)
| Constructor. More...
const ChromaFormat & | CFormat () const
| Returns the chroma format of the picture. More...
int | Xl () const
| Returns the picture width. More...
int | Yl () const
| Returns the picture height. More...
int | ChromaXl () const
| Returns the chroma width of the picture. More...
int | ChromaYl () const
| Returns the chroma height of the picture. More...
unsigned int | LumaDepth () const
| Returns the luma depth. More...
unsigned int | ChromaDepth () const
| Returns the chroma depth. More...
const PictureSort & | PicSort () const
| Returns the type of the picture. More...
int | PictureNum () const
| Returns the number of the picture (in time order) More...
int | RetiredPictureNum () const
| Returns the retired reference picture number. More...
bool | IsBPicture () const
| Returns whether the picture is bi-directionally predicted by checking references. More...
int | ExpiryTime () const
| Returns the number of pictures after the current picture number after which the picture can be discarded. More...
bool | Output () const
| Returns an indication of whether the picture has been output yet. More...
const std::vector< int > & | Refs () const
| Returns a const C++ reference to the set of reference picture numbers (will be empty if the picture is an I picture) More...
std::vector< int > & | Refs ()
| Returns non-const C++ referece to the vector of reference pictures, to allow them to be set. More...
unsigned int | NumRefs () const
| Return the number of reference pictures. More...
PictureType | GetPictureType () const
| Returns type of picture (see enum) More...
ReferenceType | GetReferenceType () const
| Returns reference picture type (see enum) More...
bool | UsingAC () const
| Returns true is entropy coding using Arithmetic coding. More...
void | SetPicSort (const PictureSort &ps)
| Sets the type of picture. More...
void | SetPictureType (const PictureType ftype)
| Sets the picture to be Intra/Inter. More...
void | SetReferenceType (const ReferenceType rtype)
| Sets the picture to be a reference or not. More...
void | SetPictureNum (const int fn)
| Sets the picture number. More...
void | SetExpiryTime (const int expt)
| Sets how long the picture will stay in the buffer (encoder only) More...
void | SetAsOutput ()
| Sets a flag to indicate that the picture has been output. More...
void | SetCFormat (ChromaFormat cf)
| Sets the chroma format. More...
void | SetXl (int xlen)
| Sets the picture width. More...
void | SetYl (int ylen)
| Sets the picture height. More...
void | SetLumaDepth (unsigned int luma_depth)
| Set Luma Depth. More...
void | SetChromaDepth (unsigned int chroma_depth)
| Set Chroma Depth. More...
void | SetRetiredPictureNum (int retd_fnum)
| Sets the retired reference picture number. More...
void | SetUsingAC (bool using_ac)
| Sets the arithmetic coding flag. More...

## Private Attributes
ChromaFormat | m_cformat
| The chroma format. More...
PictureSort | m_psort
| The picture sort. More...
std::vector< int > | m_refs
| The set of picture numbers of reference pictures. More...
int | m_expiry_time
| The number of pictures, after the current picture number, after the (de)coding of which the picture can be deleted. More...
int | m_fnum
| The picture number, in temporal order. More...
PictureType | m_picture_type
| Picture type. More...
ReferenceType | m_reference_type
| Reference type. More...
bool | m_output
| True if the picture has been output, false if not. More...
int | m_retd_fnum
| The picture number of the retired picture. More...
int | m_xl
| Picture luma width. More...
int | m_yl
| Picture luma height. More...
int | m_cxl
| Picture chroma width. More...
int | m_cyl
| Picture chroma height. More...
unsigned int | m_luma_depth
| Luma depth - number of bits required for lumz. More...
unsigned int | m_chroma_depth
| chroma depth - number of bits required for luma More...
bool | m_using_ac
| arithmetic coding flag More...

## Constructor & Destructor Documentation

## ◆ PictureParams() [1/4]

dirac::PictureParams::PictureParams | ( |  | ) |

## ◆ PictureParams() [2/4]

dirac::PictureParams::PictureParams | ( | const ChromaFormat & | cf,
|  | int | xlen,
|  | int | ylen,
|  | unsigned int | luma_depth,
|  | unsigned int | chroma_depth
| ) |  |

Picture chroma format is set Picture sort defaults to I picture.

## ◆ PictureParams() [3/4]

dirac::PictureParams::PictureParams | ( | const ChromaFormat & | cf,
|  | const PictureSort & | fs
| ) |  |

Picture chroma format and picture sort are set.

## ◆ PictureParams() [4/4]

dirac::PictureParams::PictureParams | ( | const SourceParams & | sparams | ) |

Constructor. Parameters are derived from the source parameters

## Member Function Documentation

## ◆ CFormat()

const ChromaFormat & dirac::PictureParams::CFormat | ( |  | ) | const
| inline

References m_cformat.

## ◆ ChromaDepth()

unsigned int dirac::PictureParams::ChromaDepth | ( |  | ) | const
| inline

References m_chroma_depth.

## ◆ ChromaXl()

int dirac::PictureParams::ChromaXl | ( |  | ) | const
| inline

References m_cxl.

## ◆ ChromaYl()

int dirac::PictureParams::ChromaYl | ( |  | ) | const
| inline

References m_cyl.

## ◆ ExpiryTime()

int dirac::PictureParams::ExpiryTime | ( |  | ) | const
| inline

References m_expiry_time.

## ◆ GetPictureType()

PictureType dirac::PictureParams::GetPictureType | ( |  | ) | const
| inline

References m_picture_type.

## ◆ GetReferenceType()

ReferenceType dirac::PictureParams::GetReferenceType | ( |  | ) | const
| inline

References m_reference_type.

## ◆ IsBPicture()

bool dirac::PictureParams::IsBPicture | ( |  | ) | const

## ◆ LumaDepth()

unsigned int dirac::PictureParams::LumaDepth | ( |  | ) | const
| inline

References m_luma_depth.

## ◆ NumRefs()

unsigned int dirac::PictureParams::NumRefs | ( |  | ) | const
| inline

References m_refs.

## ◆ Output()

bool dirac::PictureParams::Output | ( |  | ) | const
| inline

References m_output.

## ◆ PicSort()

const PictureSort & dirac::PictureParams::PicSort | ( |  | ) | const
| inline

References m_psort.

## ◆ PictureNum()

int dirac::PictureParams::PictureNum | ( |  | ) | const
| inline

References m_fnum.

## ◆ Refs() [1/2]

std::vector< int > & dirac::PictureParams::Refs | ( |  | ) |
| inline

References m_refs.

## ◆ Refs() [2/2]

const std::vector< int > & dirac::PictureParams::Refs | ( |  | ) | const
| inline

References m_refs.

## ◆ RetiredPictureNum()

int dirac::PictureParams::RetiredPictureNum | ( |  | ) | const
| inline

References m_retd_fnum.

## ◆ SetAsOutput()

void dirac::PictureParams::SetAsOutput | ( |  | ) |
| inline

References m_output.

## ◆ SetCFormat()

void dirac::PictureParams::SetCFormat | ( | ChromaFormat | cf | ) |
| inline

References m_cformat.

## ◆ SetChromaDepth()

void dirac::PictureParams::SetChromaDepth | ( | unsigned int | chroma_depth | ) |
| inline

References m_chroma_depth.

## ◆ SetExpiryTime()

void dirac::PictureParams::SetExpiryTime | ( | const int | expt | ) |
| inline

References m_expiry_time.

## ◆ SetLumaDepth()

void dirac::PictureParams::SetLumaDepth | ( | unsigned int | luma_depth | ) |
| inline

References m_luma_depth.

## ◆ SetPicSort()

void dirac::PictureParams::SetPicSort | ( | const PictureSort & | ps | ) |

Referenced by dirac::Picture::SetPictureSort().

## ◆ SetPictureNum()

void dirac::PictureParams::SetPictureNum | ( | const int | fn | ) |
| inline

References m_fnum.

## ◆ SetPictureType()

void dirac::PictureParams::SetPictureType | ( | const PictureType | ftype | ) |

Referenced by dirac::Picture::SetPictureType().

## ◆ SetReferenceType()

void dirac::PictureParams::SetReferenceType | ( | const ReferenceType | rtype | ) |

Referenced by dirac::Picture::SetReferenceType().

## ◆ SetRetiredPictureNum()

void dirac::PictureParams::SetRetiredPictureNum | ( | int | retd_fnum | ) |
| inline

References m_retd_fnum.

## ◆ SetUsingAC()

void dirac::PictureParams::SetUsingAC | ( | bool | using_ac | ) |
| inline

References m_using_ac.

## ◆ SetXl()

void dirac::PictureParams::SetXl | ( | int | xlen | ) |

## ◆ SetYl()

void dirac::PictureParams::SetYl | ( | int | ylen | ) |

## ◆ UsingAC()

bool dirac::PictureParams::UsingAC | ( |  | ) | const
| inline

References m_using_ac.

## ◆ Xl()

int dirac::PictureParams::Xl | ( |  | ) | const
| inline

References m_xl.

## ◆ Yl()

int dirac::PictureParams::Yl | ( |  | ) | const
| inline

References m_yl.

## Member Data Documentation

## ◆ m_cformat

ChromaFormat dirac::PictureParams::m_cformat
| private

Referenced by CFormat(), and SetCFormat().

## ◆ m_chroma_depth

unsigned int dirac::PictureParams::m_chroma_depth
| private

Referenced by ChromaDepth(), and SetChromaDepth().

## ◆ m_cxl

int dirac::PictureParams::m_cxl
| private

Referenced by ChromaXl().

## ◆ m_cyl

int dirac::PictureParams::m_cyl
| private

Referenced by ChromaYl().

## ◆ m_expiry_time

int dirac::PictureParams::m_expiry_time
| private

Referenced by ExpiryTime(), and SetExpiryTime().

## ◆ m_fnum

int dirac::PictureParams::m_fnum
| private

Referenced by PictureNum(), and SetPictureNum().

## ◆ m_luma_depth

unsigned int dirac::PictureParams::m_luma_depth
| private

Referenced by LumaDepth(), and SetLumaDepth().

## ◆ m_output

bool dirac::PictureParams::m_output
| private

Referenced by Output(), and SetAsOutput().

## ◆ m_picture_type

PictureType dirac::PictureParams::m_picture_type
| private

Referenced by GetPictureType().

## ◆ m_psort

PictureSort dirac::PictureParams::m_psort
| private

Referenced by PicSort().

## ◆ m_reference_type

ReferenceType dirac::PictureParams::m_reference_type
| private

Referenced by GetReferenceType().

## ◆ m_refs

std::vector<int> dirac::PictureParams::m_refs
| private

Referenced by NumRefs(), and Refs().

## ◆ m_retd_fnum

int dirac::PictureParams::m_retd_fnum
| mutable private

Referenced by RetiredPictureNum(), and SetRetiredPictureNum().

## ◆ m_using_ac

bool dirac::PictureParams::m_using_ac
| private

Referenced by SetUsingAC(), and UsingAC().

## ◆ m_xl

int dirac::PictureParams::m_xl
| private

Referenced by Xl().

## ◆ m_yl

int dirac::PictureParams::m_yl
| private

Referenced by Yl().

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

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