SilentEye 0.4.1
Public Member Functions | Private Attributes | Static Private Attributes

SEFormatJPEG::YCbCr Class Reference

Manage the YCbCr value for a color corresponding to a pixel (Y: luminance, Cb: blue difference, Cr: red difference) More...

#include <ycbcr.h>

List of all members.

Public Member Functions

 YCbCr (const float, const float, const float, QObject *parent=0)
 Create an YCbCr pixel from YCbCr.
 YCbCr (const QRgb &, QObject *parent=0)
 Create an YCbCr pixel from RGB.
 ~YCbCr ()
float y () const
void setY (float)
float cb () const
void setCb (float)
float cr () const
void setCr (float)
QRgb toRGB ()
 Convert the YCbCr value into RGB Color.
QString toString ()
bool operator== (const YCbCr &)
 YCbCr (const float, const float, const float, QObject *parent=0)
 Create an YCbCr pixel from YCbCr.
 YCbCr (const QRgb &, QObject *parent=0)
 Create an YCbCr pixel from RGB.
 ~YCbCr ()
float y () const
void setY (float)
float cb () const
void setCb (float)
float cr () const
void setCr (float)
QRgb toRGB ()
 Convert the YCbCr value into RGB Color.
QString toString ()
bool operator== (const YCbCr &)

Private Attributes

float m_y
 luminance
float m_cb
 blue difference
float m_cr
 red difference

Static Private Attributes

static const float kb = 0.114
 Mathematic value for conversion.
static const float kr = 0.299
 Mathematic value for conversion.

Detailed Description

Manage the YCbCr value for a color corresponding to a pixel (Y: luminance, Cb: blue difference, Cr: red difference)

Definition at line 26 of file ycbcr.h.


Constructor & Destructor Documentation

SEFormatJPEG::YCbCr::YCbCr ( const float  y,
const float  cb,
const float  cr,
QObject *  parent = 0 
)

Create an YCbCr pixel from YCbCr.

Definition at line 22 of file ycbcr.cpp.

References cb(), cr(), m_cb, m_cr, m_y, and y().

SEFormatJPEG::YCbCr::YCbCr ( const QRgb &  rgb,
QObject *  parent = 0 
)

Create an YCbCr pixel from RGB.

Definition at line 29 of file ycbcr.cpp.

References kb, kr, m_cb, m_cr, and m_y.

SEFormatJPEG::YCbCr::~YCbCr ( )

Definition at line 40 of file ycbcr.cpp.

SEFormatJPEG::YCbCr::YCbCr ( const float  ,
const float  ,
const float  ,
QObject *  parent = 0 
)

Create an YCbCr pixel from YCbCr.

SEFormatJPEG::YCbCr::YCbCr ( const QRgb &  ,
QObject *  parent = 0 
)

Create an YCbCr pixel from RGB.

SEFormatJPEG::YCbCr::~YCbCr ( )

Member Function Documentation

float SEFormatJPEG::YCbCr::cb ( ) const

Definition at line 55 of file ycbcr.cpp.

References m_cb.

Referenced by YCbCr().

float SEFormatJPEG::YCbCr::cb ( ) const
float SEFormatJPEG::YCbCr::cr ( ) const

Definition at line 65 of file ycbcr.cpp.

References m_cr.

Referenced by YCbCr().

float SEFormatJPEG::YCbCr::cr ( ) const
bool SEFormatJPEG::YCbCr::operator== ( const YCbCr color)

Definition at line 104 of file ycbcr.cpp.

References m_y, and y().

bool SEFormatJPEG::YCbCr::operator== ( const YCbCr )
void SEFormatJPEG::YCbCr::setCb ( float  value)

Definition at line 60 of file ycbcr.cpp.

References m_cb.

void SEFormatJPEG::YCbCr::setCb ( float  )
void SEFormatJPEG::YCbCr::setCr ( float  value)

Definition at line 70 of file ycbcr.cpp.

References m_cr.

void SEFormatJPEG::YCbCr::setCr ( float  )
void SEFormatJPEG::YCbCr::setY ( float  )
void SEFormatJPEG::YCbCr::setY ( float  value)

Definition at line 50 of file ycbcr.cpp.

References m_y.

QRgb SEFormatJPEG::YCbCr::toRGB ( )

Convert the YCbCr value into RGB Color.

QRgb SEFormatJPEG::YCbCr::toRGB ( )

Convert the YCbCr value into RGB Color.

Definition at line 75 of file ycbcr.cpp.

References m_cb, m_cr, and m_y.

QString SEFormatJPEG::YCbCr::toString ( )
QString SEFormatJPEG::YCbCr::toString ( )

Definition at line 96 of file ycbcr.cpp.

References m_cb, m_cr, and m_y.

float SEFormatJPEG::YCbCr::y ( ) const
float SEFormatJPEG::YCbCr::y ( ) const

Definition at line 45 of file ycbcr.cpp.

References m_y.

Referenced by operator==(), and YCbCr().


Member Data Documentation

static const float SEFormatJPEG::YCbCr::kb = 0.114 [static, private]

Mathematic value for conversion.

Definition at line 37 of file ycbcr.h.

Referenced by YCbCr().

static const float SEFormatJPEG::YCbCr::kr = 0.299 [static, private]

Mathematic value for conversion.

Definition at line 39 of file ycbcr.h.

Referenced by YCbCr().

float SEFormatJPEG::YCbCr::m_cb [private]

blue difference

Definition at line 32 of file ycbcr.h.

Referenced by cb(), setCb(), toRGB(), toString(), and YCbCr().

float SEFormatJPEG::YCbCr::m_cr [private]

red difference

Definition at line 34 of file ycbcr.h.

Referenced by cr(), setCr(), toRGB(), toString(), and YCbCr().

float SEFormatJPEG::YCbCr::m_y [private]

luminance

Definition at line 30 of file ycbcr.h.

Referenced by operator==(), setY(), toRGB(), toString(), y(), and YCbCr().


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